Use more C++17 features
Mainly structured bindings, inline variables, and class template
argument deduction, plus many more smaller things.
Change-Id: I810d17e0adb470426e4e30c898e03b3140ad052f
diff --git a/tests/daemon/rib/readvertise/readvertise.t.cpp b/tests/daemon/rib/readvertise/readvertise.t.cpp
index 8916c00..ffcab71 100644
--- a/tests/daemon/rib/readvertise/readvertise.t.cpp
+++ b/tests/daemon/rib/readvertise/readvertise.t.cpp
@@ -220,11 +220,10 @@
this->setDestinationAvailability(true);
std::set<Name> advertisedPrefixes;
boost::copy(destination->advertiseHistory | boost::adaptors::transformed(
- [] (const DummyReadvertiseDestination::HistoryEntry& he) { return he.prefix; }),
+ [] (const auto& he) { return he.prefix; }),
std::inserter(advertisedPrefixes, advertisedPrefixes.end()));
- std::set<Name> expectedPrefixes{"/A", "/B"};
- BOOST_CHECK_EQUAL_COLLECTIONS(advertisedPrefixes.begin(), advertisedPrefixes.end(),
- expectedPrefixes.begin(), expectedPrefixes.end());
+ const std::set<Name> expectedPrefixes{"/A", "/B"};
+ BOOST_TEST(advertisedPrefixes == expectedPrefixes, boost::test_tools::per_element());
destination->advertiseHistory.clear();
this->setDestinationAvailability(false);