Skip to content
This repository was archived by the owner on Mar 17, 2025. It is now read-only.

Commit 7144703

Browse files
authored
Merge pull request #241 from firebase/contrib
move modem and things to contrib dir
2 parents e1c03c5 + 4614514 commit 7144703

File tree

101 files changed

+31
-21
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

101 files changed

+31
-21
lines changed

.gitmodules

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
[submodule "test/googletest"]
2-
path = test/googletest
1+
[submodule "contrib/test/googletest"]
2+
path = contrib/test/googletest
33
url = https://github.com/google/googletest.git
4-
[submodule "test/arduino-mock"]
5-
path = test/arduino-mock
4+
[submodule "contrib/test/arduino-mock"]
5+
path = contrib/test/arduino-mock
66
url = https://github.com/ed7coyne/arduino-mock.git

.travis.yml

+3-4
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,9 @@ before_script:
2525
- ( cd ${ARDUINO_HOME}/libraries && ln -s ${TRAVIS_BUILD_DIR} firebase-arduino && ln -s ${TRAVIS_BUILD_DIR}/src/third-party/arduino-json-5.6.7 ArduinoJson && ln -s ${HOME}/SoftwareSerial ./ && ln -s ${HOME}/Adafruit_NeoPixel ./ && ln -s ${HOME}/Adafruit-GFX-Library ./ && ln -s ${HOME}/Adafruit_SSD1306 ./)
2626
script:
2727
- ${ARDUINO_ROOT}/arduino-builder -verbose -hardware ${ARDUINO_ROOT}/hardware/ -tools ${ARDUINO_ESP8266_ROOT}/tools/ -tools ${ARDUINO_ROOT}/tools-builder/ -fqbn esp8266com:esp8266:nodemcuv2 -libraries ${ARDUINO_HOME}/libraries/ -prefs build.flash_ld=${ARDUINO_ESP8266_ROOT}/tools/sdk/ld/eagle.flash.4m.ld -prefs build.flash_freq=40 -prefs build.flash_size=4M examples/FirebaseDemo_ESP8266/FirebaseDemo_ESP8266.ino
28-
- ${ARDUINO_ROOT}/arduino-builder -verbose -hardware ${ARDUINO_ROOT}/hardware/ -tools ${ARDUINO_ESP8266_ROOT}/tools/ -tools ${ARDUINO_ROOT}/tools-builder/ -fqbn esp8266com:esp8266:nodemcuv2 -libraries ${ARDUINO_HOME}/libraries/ -prefs build.flash_ld=${ARDUINO_ESP8266_ROOT}/tools/sdk/ld/eagle.flash.4m.ld -prefs build.flash_freq=40 -prefs build.flash_size=4M examples/FirebaseSerialHost_ESP8266/FirebaseSerialHost_ESP8266.ino
2928
- ${ARDUINO_ROOT}/arduino-builder -verbose -hardware ${ARDUINO_ROOT}/hardware/ -tools ${ARDUINO_ESP8266_ROOT}/tools/ -tools ${ARDUINO_ROOT}/tools-builder/ -fqbn esp8266com:esp8266:nodemcuv2 -libraries ${ARDUINO_HOME}/libraries/ -prefs build.flash_ld=${ARDUINO_ESP8266_ROOT}/tools/sdk/ld/eagle.flash.4m.ld -prefs build.flash_freq=40 -prefs build.flash_size=4M examples/FirebaseNeoPixel_ESP8266/FirebaseNeoPixel_ESP8266.ino
3029
- ${ARDUINO_ROOT}/arduino-builder -verbose -hardware ${ARDUINO_ROOT}/hardware/ -tools ${ARDUINO_ESP8266_ROOT}/tools/ -tools ${ARDUINO_ROOT}/tools-builder/ -fqbn esp8266com:esp8266:nodemcuv2 -libraries ${ARDUINO_HOME}/libraries/ -prefs build.flash_ld=${ARDUINO_ESP8266_ROOT}/tools/sdk/ld/eagle.flash.4m.ld -prefs build.flash_freq=40 -prefs build.flash_size=4M examples/FirebaseStream_ESP8266/FirebaseStream_ESP8266.ino
3130
- ${ARDUINO_ROOT}/arduino-builder -verbose -hardware ${ARDUINO_ROOT}/hardware/ -tools ${ARDUINO_ESP8266_ROOT}/tools/ -tools ${ARDUINO_ROOT}/tools-builder/ -fqbn esp8266com:esp8266:nodemcuv2 -libraries ${ARDUINO_HOME}/libraries/ -prefs build.flash_ld=${ARDUINO_ESP8266_ROOT}/tools/sdk/ld/eagle.flash.4m.ld -prefs build.flash_freq=40 -prefs build.flash_size=4M examples/FirebaseRoom_ESP8266/FirebaseRoom_ESP8266.ino
32-
- ( cd test && make check )
33-
- ( cd test/modem/ && make test )
34-
- test/travis/check_all_examples_use_standard_init.sh
31+
- ( cd contrib/test && make check )
32+
- ( cd contrib/test/modem/ && make test )
33+
- contrib/test/travis/check_all_examples_use_standard_init.sh

contrib/README.md

+8
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

test/Makefile renamed to contrib/test/Makefile

+3-3
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@
1414
# limitations under the License.
1515
#
1616

17-
FIREBASE_DIR=..
17+
FIREBASE_DIR=../..
1818
GTEST_DIR=googletest/googletest
19-
ARDUINOJSON_DIR=../src/third-party/arduino-json-5.6.7
19+
ARDUINOJSON_DIR=../../src/third-party/arduino-json-5.6.7
2020

2121
FIREBASE_SRCS=${FIREBASE_DIR}/src/FirebaseObject.cpp
2222
GTEST_SRCS=${GTEST_DIR}/src/gtest-all.cpp
@@ -27,7 +27,7 @@ SRCS=FirebaseArduino_test.cpp\
2727

2828
OBJS=${SRCS:.cpp=.o}
2929

30-
CXXFLAGS=-I. -I../src -Igoogletest/googletest/include -Igoogletest/googletest -std=c++11 -g
30+
CXXFLAGS=-I. -I${FIREBASE_DIR}/src -Igoogletest/googletest/include -Igoogletest/googletest -std=c++11 -g
3131
LDFLAGS=-lpthread
3232

3333
all: check
File renamed without changes.

contrib/test/arduino-mock

Submodule arduino-mock added at 0f7f9fa
File renamed without changes.
File renamed without changes.

contrib/test/googletest

Submodule googletest added at a2b8a8e
File renamed without changes.

test/modem/Makefile renamed to contrib/test/modem/Makefile

+6-3
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,10 @@ ARDUINO_MOCK_DIR = ../arduino-mock/
3030
# Where to find user code.
3131
TEST_DIR = .
3232

33-
PROJECT_ROOT = ../../
33+
FIREBASE_ROOT = ../../..
34+
PROJECT_ROOT = ../..
3435
SRC_ROOT = $(PROJECT_ROOT)/src
36+
FIREBASE_SRC_ROOT = $(FIREBASE_ROOT)/src
3537

3638
# Flags passed to the preprocessor.
3739
# Set Google Test and Google Mock's header directories as system
@@ -42,6 +44,7 @@ CPPFLAGS += -isystem $(GTEST_DIR)/include -isystem $(GMOCK_DIR)/include \
4244
-I$(ARDUINO_MOCK_DIR)/include/ \
4345
-I$(PROJECT_ROOT)/test/dummies \
4446
-I$(PROJECT_ROOT)/src \
47+
-I$(FIREBASE_ROOT)/src \
4548
-I$(PROJECT_ROOT)
4649

4750
# Flags passed to the C++ compiler.
@@ -125,8 +128,8 @@ arduino_mock_all.a : ArduinoMockAll.o
125128

126129
# Builds shared objects.
127130

128-
Firebase.o : $(SRC_ROOT)/Firebase.cpp
129-
$(CXX) $(CPPFLAGS) $(CXXFLAGS) -c $(SRC_ROOT)/Firebase.cpp
131+
Firebase.o : $(FIREBASE_SRC_ROOT)/Firebase.cpp
132+
$(CXX) $(CPPFLAGS) $(CXXFLAGS) -c $(FIREBASE_SRC_ROOT)/Firebase.cpp
130133

131134
FirebaseHttpClient_dummy.o : $(PROJECT_ROOT)/test/dummies/FirebaseHttpClient_dummy.cpp
132135
$(CXX) $(CPPFLAGS) $(CXXFLAGS) -c $(PROJECT_ROOT)/test/dummies/FirebaseHttpClient_dummy.cpp
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
#!/bin/bash
2-
FBASE_SNIPPET=test/travis/firebase_init.cc.snip
3-
FBASE_NOAUTH_SNIPPET=test/travis/no_firebase_init.cc.snip
4-
FBASE_NOCONFIG_SNIPPET=test/travis/no_config_init.cc.snip
5-
for example in `find examples/ -name *.ino`;
2+
FBASE_SNIPPET=contrib/test/travis/firebase_init.cc.snip
3+
FBASE_NOAUTH_SNIPPET=contrib/test/travis/no_firebase_init.cc.snip
4+
FBASE_NOCONFIG_SNIPPET=contrib/test/travis/no_config_init.cc.snip
5+
for example in `find examples/ contrib/examples/ -name *.ino`;
66
do
77
echo $example;
88
(xxd -p $example | tr -d '\n' | grep -q `xxd -p $FBASE_SNIPPET | tr -d '\n'`) ||
99
(xxd -p $example | tr -d '\n' | grep -q `xxd -p $FBASE_NOAUTH_SNIPPET | tr -d '\n'`) ||
1010
(xxd -p $example | tr -d '\n' | grep -q `xxd -p $FBASE_NOCONFIG_SNIPPET | tr -d '\n'`) ||
1111
if [ $? -ne 0 ];
1212
then
13-
echo $example does not contain standard defined in test/travis/*_init.cc.snip.
13+
echo $example does not contain standard defined in contrib/test/travis/*_init.cc.snip.
1414
exit 1;
1515
fi;
1616
done;

test/arduino-mock

-1
This file was deleted.

test/googletest

-1
This file was deleted.

0 commit comments

Comments
 (0)