aboutsummaryrefslogtreecommitdiff
path: root/sensor/test
diff options
context:
space:
mode:
Diffstat (limited to 'sensor/test')
-rw-r--r--sensor/test/SampleTest.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/sensor/test/SampleTest.cpp b/sensor/test/SampleTest.cpp
index 8479e75..0fffc04 100644
--- a/sensor/test/SampleTest.cpp
+++ b/sensor/test/SampleTest.cpp
@@ -49,13 +49,13 @@ BOOST_AUTO_TEST_CASE(key_value_parser2) {
SampleRecord& sample = buffer->samples[0];
auto it = dict.begin();
BOOST_CHECK_EQUAL((*it)->name, "now");
- BOOST_CHECK_EQUAL(!sample.at(*it).operator!(), true);
- BOOST_CHECK_EQUAL(sample.at(*it).get(), "1");
+ BOOST_CHECK_EQUAL(!!sample.at(*it), true);
+ BOOST_CHECK_EQUAL(sample.at(*it).value(), "1");
BOOST_CHECK_EQUAL((*it++)->index, 0);
BOOST_CHECK_EQUAL((*it)->name, "sensor 1");
- BOOST_CHECK_EQUAL(!sample.at(*it).operator!(), true);
- BOOST_CHECK_EQUAL(sample.at(*it).get(), "0.000999999833333");
+ BOOST_CHECK_EQUAL(!!sample.at(*it), true);
+ BOOST_CHECK_EQUAL(sample.at(*it).value(), "0.000999999833333");
BOOST_CHECK_EQUAL((*it++)->index, 1);
}
@@ -112,12 +112,12 @@ BOOST_AUTO_TEST_CASE(key_value_parser_without_newline) {
SampleRecord& sample = buffer->samples[0];
auto it = dict.begin();
BOOST_CHECK_EQUAL((*it)->name, "now");
- BOOST_CHECK_EQUAL(!sample.at(*it).operator!(), true);
- BOOST_CHECK_EQUAL(sample.at(*it).get(), "1");
+ BOOST_CHECK_EQUAL(!!sample.at(*it), true);
+ BOOST_CHECK_EQUAL(sample.at(*it).value(), "1");
BOOST_CHECK_EQUAL((*it++)->index, 0);
BOOST_CHECK_EQUAL((*it)->name, "sensor");
- BOOST_CHECK_EQUAL(!sample.at(*it).operator!(), true);
- BOOST_CHECK_EQUAL(sample.at(*it).get(), "123");
+ BOOST_CHECK_EQUAL(!!sample.at(*it), true);
+ BOOST_CHECK_EQUAL(sample.at(*it).value(), "123");
BOOST_CHECK_EQUAL((*it++)->index, 1);
}