diff --git a/firmware/controllers/sensors/sensor.cpp b/firmware/controllers/sensors/sensor.cpp index 77adb53e01..2406ee5d26 100644 --- a/firmware/controllers/sensors/sensor.cpp +++ b/firmware/controllers/sensors/sensor.cpp @@ -35,7 +35,6 @@ bool Sensor::Register() { auto &entry = s_sensorRegistry[i]; entry.sensor = nullptr; - entry.useMock = false; entry.mockValue = 0.0f; } } diff --git a/unit_tests/tests/sensor/mock_sensor.cpp b/unit_tests/tests/sensor/mock_sensor.cpp index dad911f50f..789241732a 100644 --- a/unit_tests/tests/sensor/mock_sensor.cpp +++ b/unit_tests/tests/sensor/mock_sensor.cpp @@ -90,28 +90,3 @@ TEST_F(SensorMocking, ResetAll) { EXPECT_FLOAT_EQ(result.Value, 46.0f); } } - -TEST_F(SensorMocking, ResetWithResetRegistry) { - // Set a value on the "real" sensor - realSensor.set(46.0f); - - // Now set a mock value - Sensor::setMockValue(SensorType::Clt, 33.0f); - - // Expect to see the mock value - { - auto result = Sensor::get(SensorType::Clt); - EXPECT_TRUE(result.Valid); - EXPECT_FLOAT_EQ(result.Value, 33.0f); - } - - // Reset registry - including mocks - Sensor::resetRegistry(); - - { - auto result = Sensor::get(SensorType::Clt); - EXPECT_TRUE(result.Valid); - EXPECT_FLOAT_EQ(result.Value, 46.0f); - } -} -