blob: 3a615192dd2d7987907fa76e25e802711564606e [file] [log] [blame]
Krzysztof Grobelnyb5645942020-09-29 11:52:45 +02001#pragma once
2
3#include "interfaces/sensor_listener.hpp"
4
5#include <gmock/gmock.h>
6
7class SensorListenerMock : public interfaces::SensorListener
8{
9 public:
10 void delegateIgnoringArgs()
11 {
12 using namespace testing;
13
Wludzik, Jozef0e29f432020-11-17 08:22:33 +010014 ON_CALL(*this, sensorUpdated(_, _))
15 .WillByDefault(InvokeWithoutArgs([this] { sensorUpdated(); }));
Krzysztof Grobelnyb5645942020-09-29 11:52:45 +020016
Wludzik, Jozef0e29f432020-11-17 08:22:33 +010017 ON_CALL(*this, sensorUpdated(_, _, _))
18 .WillByDefault(InvokeWithoutArgs([this] { sensorUpdated(); }));
Krzysztof Grobelnyb5645942020-09-29 11:52:45 +020019 }
20
21 MOCK_METHOD(void, sensorUpdated, (interfaces::Sensor&, uint64_t),
22 (override));
23 MOCK_METHOD(void, sensorUpdated, (interfaces::Sensor&, uint64_t, double),
24 (override));
25
26 MOCK_METHOD(void, sensorUpdated, (), ());
27};