mirror of
https://gitlab.com/Luci_/arduino-photometrics.git
synced 2026-04-03 11:35:37 +02:00
add test_init.py, change for cli gitlab
This commit is contained in:
parent
ba39b4c849
commit
0a5f9a149b
|
|
@ -19,7 +19,7 @@ pio_build:
|
||||||
|
|
||||||
before_script:
|
before_script:
|
||||||
- pip install -U platformio
|
- pip install -U platformio
|
||||||
- pio lib install "ThrowTheSwitch/Unity@^2.6.0"
|
# - pio lib install "ThrowTheSwitch/Unity@^2.6.0"
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- "pio run -e $ARDUINO_ENV"
|
- "pio run -e $ARDUINO_ENV"
|
||||||
|
|
@ -32,5 +32,6 @@ pio_test:
|
||||||
- pip install -U platformio
|
- pip install -U platformio
|
||||||
|
|
||||||
script:
|
script:
|
||||||
- pio ci --lib='.' --board=$ARDUINO_ENV test/EEPROM_test_struct.cpp
|
- pio test -e $ARDUINO_ENV --without-upload
|
||||||
# - "pio ci --lib='.' --board=$ARDUINO_ENV test"
|
# - pio ci --lib='.' --board=$ARDUINO_ENV test/EEPROM_test_struct.cpp
|
||||||
|
# - "pio ci --lib='.' --board=$ARDUINO_ENV test"
|
||||||
|
|
@ -16,7 +16,7 @@ test_framework = unity
|
||||||
;upload_port = /dev/ttyACM0
|
;upload_port = /dev/ttyACM0
|
||||||
build_flags =
|
build_flags =
|
||||||
-std=gnu++17
|
-std=gnu++17
|
||||||
-I lib/ test/
|
-I lib/
|
||||||
;-D DEBUG
|
;-D DEBUG
|
||||||
lib_deps =
|
lib_deps =
|
||||||
northernwidget/DS3231@^1.1.2
|
northernwidget/DS3231@^1.1.2
|
||||||
|
|
@ -24,3 +24,8 @@ lib_deps =
|
||||||
robtillaart/CRC
|
robtillaart/CRC
|
||||||
|
|
||||||
lib_ldf_mode = deep+
|
lib_ldf_mode = deep+
|
||||||
|
|
||||||
|
test_lib_deps =
|
||||||
|
ThrowTheSwitch/Unity@^2.6.0
|
||||||
|
|
||||||
|
extra_scripts = pre:test_init.py
|
||||||
12
test_init.py
Normal file
12
test_init.py
Normal file
|
|
@ -0,0 +1,12 @@
|
||||||
|
# test_init.py
|
||||||
|
|
||||||
|
Import("env")
|
||||||
|
test_env_name = env["PIOENV"]
|
||||||
|
|
||||||
|
# Injecte manuellement les chemins d'inclusion nécessaires (Unity et votre config)
|
||||||
|
env.Append(
|
||||||
|
CPPPATH=[
|
||||||
|
"test",
|
||||||
|
".pio/libdeps/" + test_env_name + "/Unity/src"
|
||||||
|
]
|
||||||
|
)
|
||||||
Loading…
Reference in a new issue