Implemented sensor class
Sensor class was introduced, it monitors
xyz.openbmc_project.Sensor.Value, for change and notifies all
listeners.
Tested:
- Unit tested with service stub that provides dbus interface
xyz.openbmc_project.Sensor.Value
- All changes are delivered to listeners
- All other unit tests are passing
Change-Id: I8c9d58cc986c1fe2a4d2386815d559814016efa6
Signed-off-by: Krzysztof Grobelny <krzysztof.grobelny@intel.com>
diff --git a/tests/src/test_sensor_cache.cpp b/tests/src/test_sensor_cache.cpp
index 5be9a0d..a3831dc 100644
--- a/tests/src/test_sensor_cache.cpp
+++ b/tests/src/test_sensor_cache.cpp
@@ -1,5 +1,6 @@
#include "mocks/sensor_mock.hpp"
#include "sensor_cache.hpp"
+#include "utils/sensor_id_eq.hpp"
#include <initializer_list>
@@ -13,13 +14,6 @@
SensorCache sut;
};
-auto sensorIdEq(interfaces::Sensor::Id id)
-{
- return AllOf(Field(&interfaces::Sensor::Id::type, Eq(id.type)),
- Field(&interfaces::Sensor::Id::service, Eq(id.service)),
- Field(&interfaces::Sensor::Id::path, Eq(id.path)));
-}
-
struct IdParam
{
IdParam() = default;