Hotwheels-Cluster 1.2
Creation of Cluster APP for SEA:ME project.
 
Loading...
Searching...
No Matches
MockI2CController.hpp
Go to the documentation of this file.
1
14
15#ifndef MOCKI2CCONTROLLER_HPP
16#define MOCKI2CCONTROLLER_HPP
17
18#include "II2CController.hpp"
19#include <gmock/gmock.h>
20
26{
27public:
29 MOCK_METHOD(void, writeRegister, (uint8_t reg, uint16_t value), (override));
31 MOCK_METHOD(uint16_t, readRegister, (uint8_t reg), (override));
32};
33
34#endif // MOCKI2CCONTROLLER_HPP
Definition of the II2CController interface.
Interface for controlling I2C devices.
virtual uint16_t readRegister(uint8_t reg)=0
virtual void writeRegister(uint8_t reg, uint16_t value)=0
Class to emulate the behavior of the I2C controller.
MOCK_METHOD(uint16_t, readRegister,(uint8_t reg),(override))
Mocked method to read a register from the I2C controller.
MOCK_METHOD(void, writeRegister,(uint8_t reg, uint16_t value),(override))
Mocked method to initialize the I2C controller.