summaryrefslogtreecommitdiffstats
path: root/googletest/src/gtest_main.cc
diff options
context:
space:
mode:
authorvslashg <gfalcon@google.com>2019-10-25 14:21:03 (GMT)
committervslashg <gfalcon@google.com>2019-10-25 14:21:03 (GMT)
commit540835fa687e73c9d634c710e62a721c2be40786 (patch)
tree7103d19b9edeff546e862b88b6e90226382f81de /googletest/src/gtest_main.cc
parent37f322783175a66c11785d17fc153477b0777753 (diff)
parent778733f9ecdd2b14a0167df54dd25d2d6f6e24f6 (diff)
downloadgoogletest-540835fa687e73c9d634c710e62a721c2be40786.zip
googletest-540835fa687e73c9d634c710e62a721c2be40786.tar.gz
googletest-540835fa687e73c9d634c710e62a721c2be40786.tar.bz2
Merge pull request #2515 from ciband:feat/support_esp8266
PiperOrigin-RevId: 276333426
Diffstat (limited to 'googletest/src/gtest_main.cc')
-rw-r--r--googletest/src/gtest_main.cc9
1 files changed, 8 insertions, 1 deletions
diff --git a/googletest/src/gtest_main.cc b/googletest/src/gtest_main.cc
index f6e1dd9..46b27c3 100644
--- a/googletest/src/gtest_main.cc
+++ b/googletest/src/gtest_main.cc
@@ -30,13 +30,20 @@
#include <cstdio>
#include "gtest/gtest.h"
-#ifdef ARDUINO
+#if GTEST_OS_ESP8266 || GTEST_OS_ESP32
+#if GTEST_OS_ESP8266
+extern "C" {
+#endif
void setup() {
testing::InitGoogleTest();
}
void loop() { RUN_ALL_TESTS(); }
+#if GTEST_OS_ESP8266
+}
+#endif
+
#else
GTEST_API_ int main(int argc, char **argv) {