summaryrefslogtreecommitdiffstats
path: root/test/sensor_manager_unittest.cpp
diff options
context:
space:
mode:
authorJames Feist <james.feist@linux.intel.com>2019-05-07 09:17:16 -0700
committerJames Feist <james.feist@linux.intel.com>2019-05-09 17:08:41 +0000
commit1fe08952e5bc827003a0621ae4cf7e688a458eb8 (patch)
tree2b681c5ee1354aefd52f075700e2003f5d0df575 /test/sensor_manager_unittest.cpp
parent0c8223b5f5c280276d432eab5e32694a90451239 (diff)
downloadphosphor-pid-control-1fe08952e5bc827003a0621ae4cf7e688a458eb8.tar.gz
phosphor-pid-control-1fe08952e5bc827003a0621ae4cf7e688a458eb8.zip
Make dbusconfiguration reloadable without reboot
Now that asio is being used instead of threads, we can reload the fan configuration without having to restart the application. This moves the ownership of the passive and host bus outside of the SensorManager so that it can be recreated each reload. Tested: Watched logs and saw full fan config get reloaded after changing fan configuration Tested: Ran on json configured system and it behaved as expected. Change-Id: I00e6b27f75384fd41de2017b723f159c9691ae97 Signed-off-by: James Feist <james.feist@linux.intel.com>
Diffstat (limited to 'test/sensor_manager_unittest.cpp')
-rw-r--r--test/sensor_manager_unittest.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/sensor_manager_unittest.cpp b/test/sensor_manager_unittest.cpp
index 8a89628..9f0e26c 100644
--- a/test/sensor_manager_unittest.cpp
+++ b/test/sensor_manager_unittest.cpp
@@ -24,7 +24,7 @@ TEST(SensorManagerTest, BoringConstructorTest)
IsNull(), _, StrEq("/xyz/openbmc_project/extsensors")))
.WillOnce(Return(0));
- SensorManager s(std::move(bus_mock_passive), std::move(bus_mock_host));
+ SensorManager s(bus_mock_passive, bus_mock_host);
// Success
}
@@ -43,7 +43,7 @@ TEST(SensorManagerTest, AddSensorInvalidTypeTest)
IsNull(), _, StrEq("/xyz/openbmc_project/extsensors")))
.WillOnce(Return(0));
- SensorManager s(std::move(bus_mock_passive), std::move(bus_mock_host));
+ SensorManager s(bus_mock_passive, bus_mock_host);
std::string name = "name";
std::string type = "invalid";
OpenPOWER on IntegriCloud