Macros | Functions
table_insertionOperator_t.cc File Reference
#include "boost/test/unit_test.hpp"
#include "fhiclcpp/types/Atom.h"
#include "fhiclcpp/types/OptionalTable.h"
#include "fhiclcpp/types/Table.h"
#include "fhiclcpp/types/detail/optional_parameter_message.h"
#include <iostream>
#include <string>

Go to the source code of this file.

Macros

#define BOOST_TEST_MODULE   (table_insertionOperator_t)
 

Functions

 BOOST_AUTO_TEST_CASE (simple)
 
 BOOST_AUTO_TEST_CASE (logger)
 
 BOOST_AUTO_TEST_CASE (loggerOptional)
 

Macro Definition Documentation

#define BOOST_TEST_MODULE   (table_insertionOperator_t)

Definition at line 7 of file table_insertionOperator_t.cc.

Function Documentation

BOOST_AUTO_TEST_CASE ( simple  )

Definition at line 72 of file table_insertionOperator_t.cc.

73 {
74  Table<Config> config{Name("config")};
75  ostringstream oss;
76  oss << config;
77  auto const& test = oss.str();
78  auto const& ref = reference();
79  BOOST_TEST(test == ref);
80 }
ChannelGroupService::Name Name
static Config * config
Definition: config.cpp:1054
BOOST_AUTO_TEST_CASE ( logger  )

Definition at line 82 of file table_insertionOperator_t.cc.

83 {
84  Table<Config> config{Name("config")};
85  Logger logger;
86  logger << config;
87  BOOST_TEST(logger.log == reference());
88 
89  Logger const logger2 = (Logger() << config);
90  BOOST_TEST(logger2.log == reference());
91 }
ChannelGroupService::Name Name
static Config * config
Definition: config.cpp:1054
BOOST_AUTO_TEST_CASE ( loggerOptional  )

Definition at line 93 of file table_insertionOperator_t.cc.

94 {
96  Logger logger;
97  logger << config;
98  BOOST_TEST(logger.log == optional_reference());
99 
100  Logger const logger2 = (Logger() << config);
101  BOOST_TEST(logger2.log == optional_reference());
102 }
ChannelGroupService::Name Name
static Config * config
Definition: config.cpp:1054