Skip to content

Commit 140a136

Browse files
committed
Fix class EEPROM->EEPROM_, WiFi->WiFi_
1 parent 93881c8 commit 140a136

File tree

6 files changed

+27
-27
lines changed

6 files changed

+27
-27
lines changed

include/arduino-mock/eeprom.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ EEPROM mock
88
#include <stdint.h>
99
#include <gmock/gmock.h>
1010

11-
class EEPROM {
11+
class EEPROM_ {
1212
public:
1313
uint8_t read(int a);
1414
void write(int a, uint8_t b);
@@ -23,4 +23,4 @@ class EEPROMMock {
2323

2424
EEPROMMock* EEPROMMockInstance();
2525
void releaseEEPROMMock();
26-
#endif
26+
#endif

include/arduino-mock/wifi.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
#include <gmock/gmock.h>
77
#include <stdint.h>
88

9-
class WiFi {
9+
class WiFi_ {
1010
public:
1111
void on(); // turns on WiFi module
1212
void off(); // turns off WiFi module

src/eeprom.cc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,10 @@ void releaseEEPROMMock() {
1717
}
1818
}
1919

20-
uint8_t EEPROM::read(int a) {
20+
uint8_t EEPROM_::read(int a) {
2121
return p_EEPROMMock->read(a);
2222
}
2323

24-
void EEPROM::write(int a, uint8_t b) {
24+
void EEPROM_::write(int a, uint8_t b) {
2525
p_EEPROMMock->write(a, b);
26-
}
26+
}

src/wifi.cc

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -15,78 +15,78 @@ void releaseWiFiMock() {
1515
}
1616
}
1717

18-
void WiFi::on() {
18+
void WiFi_::on() {
1919
p_WiFiMock->on();
2020
}
2121

22-
void WiFi::off() {
22+
void WiFi_::off() {
2323
p_WiFiMock->off();
2424
}
2525

26-
void WiFi::connect() {
26+
void WiFi_::connect() {
2727
p_WiFiMock->connect();
2828
}
2929

30-
void WiFi::disconnect() {
30+
void WiFi_::disconnect() {
3131
p_WiFiMock->disconnect();
3232
}
3333

34-
bool WiFi::connecting() {
34+
bool WiFi_::connecting() {
3535
return p_WiFiMock->connecting();
3636
}
3737

38-
bool WiFi::ready() {
38+
bool WiFi_::ready() {
3939
return p_WiFiMock->ready();
4040
}
4141

42-
void WiFi::listen() {
42+
void WiFi_::listen() {
4343
p_WiFiMock->listen();
4444
}
4545

46-
bool WiFi::listening() {
46+
bool WiFi_::listening() {
4747
return p_WiFiMock->listening();
4848
}
4949

50-
void WiFi::setCredentials() {
50+
void WiFi_::setCredentials() {
5151
p_WiFiMock->setCredentials();
5252
}
5353

54-
bool WiFi::clearCredentials() {
54+
bool WiFi_::clearCredentials() {
5555
return p_WiFiMock->clearCredentials();
5656
}
5757

58-
bool WiFi::hasCredentials() {
58+
bool WiFi_::hasCredentials() {
5959
return p_WiFiMock->hasCredentials();
6060
}
6161

62-
uint8_t WiFi::macAddress() {
62+
uint8_t WiFi_::macAddress() {
6363
return p_WiFiMock->macAddress();
6464
}
6565

66-
char* WiFi::SSID() {
66+
char* WiFi_::SSID() {
6767
return p_WiFiMock->SSID();
6868
}
6969

70-
int WiFi::RSSI() {
70+
int WiFi_::RSSI() {
7171
return p_WiFiMock->RSSI();
7272
}
7373

74-
void WiFi::ping(char* a) {
74+
void WiFi_::ping(char* a) {
7575
p_WiFiMock->ping(a);
7676
}
7777

78-
void WiFi::ping(char* a, uint8_t b) {
78+
void WiFi_::ping(char* a, uint8_t b) {
7979
p_WiFiMock->ping(a, b);
8080
}
8181

82-
char* WiFi::localIP() {
82+
char* WiFi_::localIP() {
8383
return p_WiFiMock->localIP();
8484
}
8585

86-
char* WiFi::subnetMask() {
86+
char* WiFi_::subnetMask() {
8787
return p_WiFiMock->subnetMask();
8888
}
8989

90-
char* WiFi::gatewayIP() {
90+
char* WiFi_::gatewayIP() {
9191
return p_WiFiMock->gatewayIP();
9292
}

test/eeprom_unittest.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#include "gtest/gtest.h"
22
#include "arduino-mock/eeprom.h"
33
#include "arduino-mock/arduino.h"
4-
EEPROM eeprom;
4+
EEPROM_ eeprom;
55
using ::testing::Return;
66

77
TEST(eeprom, access) {

test/wifi_unittest.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#include "arduino-mock/wifi.h"
33
#include "arduino-mock/arduino.h"
44

5-
WiFi wifi;
5+
WiFi_ wifi;
66

77
using ::testing::Return;
88
TEST(wire, access) {

0 commit comments

Comments
 (0)