aboutsummaryrefslogtreecommitdiffstats
path: root/host/tests/graph_search_test.cpp
diff options
context:
space:
mode:
authorAndrej Rode <andrej.rode@ettus.com>2017-02-09 23:19:55 -0800
committerMartin Braun <martin.braun@ettus.com>2017-02-10 16:44:33 -0800
commit26cc20847cde543e759aa5cee9a27eaa69c5dd9e (patch)
treeeee102333381e2313af59e725d6b7a06b665161f /host/tests/graph_search_test.cpp
parentf3a004faf7d50cbb5564f5e2f67f54ee07e051dd (diff)
downloaduhd-26cc20847cde543e759aa5cee9a27eaa69c5dd9e.tar.gz
uhd-26cc20847cde543e759aa5cee9a27eaa69c5dd9e.tar.bz2
uhd-26cc20847cde543e759aa5cee9a27eaa69c5dd9e.zip
uhd: replace BOOST_FOREACH with C++11 range-based for loop
Note: This is the first commit that uses for-range, and range-based for-loops are now usable for UHD development.
Diffstat (limited to 'host/tests/graph_search_test.cpp')
-rw-r--r--host/tests/graph_search_test.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/host/tests/graph_search_test.cpp b/host/tests/graph_search_test.cpp
index 8c96bb954..d39f767e9 100644
--- a/host/tests/graph_search_test.cpp
+++ b/host/tests/graph_search_test.cpp
@@ -83,7 +83,7 @@ BOOST_AUTO_TEST_CASE(test_linear_downstream_search)
std::cout << "size: " << result.size() << std::endl;
BOOST_CHECK_EQUAL(result.size(), 1);
BOOST_CHECK_EQUAL(result[0]->get_test_id(), "node_B");
- BOOST_FOREACH(const result_node::sptr &node, result) {
+ for(const result_node::sptr &node: result) {
std::cout << node->get_test_id() << std::endl;
}
}
@@ -111,7 +111,7 @@ BOOST_AUTO_TEST_CASE(test_multi_iter_downstream_search)
// This time, we search for result_node
std::vector< result_node::sptr > result = node_A->find_downstream_node<result_node>();
BOOST_REQUIRE(result.size() == 4);
- BOOST_FOREACH(const result_node::sptr &node, result) {
+ for(const result_node::sptr &node: result) {
std::cout << node->get_test_id() << std::endl;
}
}
@@ -140,7 +140,7 @@ BOOST_AUTO_TEST_CASE(test_multi_iter_cycle_downstream_search)
// This time, we search for result_node
std::vector< result_node::sptr > result = node_A->find_downstream_node<result_node>();
BOOST_REQUIRE(result.size() == 4);
- BOOST_FOREACH(const result_node::sptr &node, result) {
+ for(const result_node::sptr &node: result) {
std::cout << node->get_test_id() << std::endl;
}
}