1 #define BOOST_TEST_MODULE (get via converter test) 2 #include "boost/test/unit_test.hpp" 10 using namespace fhicl;
15 std::vector<std::string>
names;
19 to_sorted_names(std::vector<std::string>
const&
names)
27 BOOST_AUTO_TEST_SUITE(via_test)
31 auto const config =
"number: 5 " 32 "names: ['Esther', 'Julian', 'Bobby']"s;
34 BOOST_TEST(pset.get<
int>(
"number") == 5);
36 auto check_value = [](
int const& i) {
return i == 5; };
37 auto const supplied_5 = pset.get<
bool,
int>(
"number", check_value);
38 BOOST_TEST(supplied_5);
40 auto const sorted_names = pset.get(
"names", to_sorted_names);
42 BOOST_TEST(sorted_names.names == ref);
45 BOOST_AUTO_TEST_SUITE_END()
static ParameterSet make(intermediate_table const &tbl)
void sort_all(RandCont &)
static std::vector< std::string > const names
BOOST_AUTO_TEST_CASE(via_test)