Skip to content

Commit efa1758

Browse files
committed
πŸ§‘β€πŸ’» Allow for tests on macOS / Windows
1 parent 448ff71 commit efa1758

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

β€ŽMakefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ help:
1717
@echo "make tests-all-local-docker : Run all tests locally, using docker"
1818
@echo "make unit-test-single-local : Run unit tests for a single config locally"
1919
@echo "make unit-test-single-local-docker : Run unit tests for a single config locally, using docker"
20-
@echo "make unit-test-all-local : Run all code tests locally"
20+
@echo "make unit-test-all-local : Run all code tests locally"
2121
@echo "make unit-test-all-local-docker : Run all code tests locally, using docker"
2222
@echo "make setup-local-docker : Setup local docker using buildx"
2323
@echo ""

β€ŽMarlin/src/pins/pins.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -985,7 +985,7 @@
985985
//
986986

987987
#elif MB(SIMULATED)
988-
#include "native/pins_RAMPS_NATIVE.h" // Native or Simulation lin:linux_native mac:simulator_macos_debug mac:simulator_macos_release win:simulator_windows lin:simulator_linux_debug lin:simulator_linux_release
988+
#include "native/pins_RAMPS_NATIVE.h" // Native or Simulation lin:linux_native lin:simulator_linux_debug lin:simulator_linux_release lin:linux_native_test mac:simulator_macos_debug mac:simulator_macos_release win:simulator_windows
989989

990990
#else
991991

β€Žbuildroot/share/PlatformIO/scripts/collect-code-tests.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#
22
# collect-code-tests.py
3-
# Convenience script to collect all code tests. Used by env:linux_native_test in native.ini.
3+
# Convenience script to collect all code tests. Used by test envs in native.ini.
44
#
55

66
import pioutil
@@ -32,7 +32,7 @@ def register_test_suites():
3232
"restore_configs",
3333
f"cp -f {path} ./Marlin/config.ini",
3434
"python ./buildroot/share/PlatformIO/scripts/configuration.py",
35-
f"platformio test -e linux_native_test -f {name}",
35+
f"platformio test -e {env['PIOENV']} -f {name}",
3636
"restore_configs",
3737
],
3838
title = "Marlin: {}".format(name.lower().title().replace("_", " ")),
@@ -46,7 +46,7 @@ def register_test_suites():
4646
name = "test-marlin",
4747
dependencies = None,
4848
actions = [
49-
f"platformio run -t marlin_{name} -e linux_native_test"
49+
f"platformio run -t marlin_{name} -e {env['PIOENV']}"
5050
for name in targets
5151
],
5252
title = "Marlin: Test all code test suites",

β€Žbuildroot/share/PlatformIO/scripts/preflight-checks.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ def sanity_check_target():
9595

9696
# Make sure board is compatible with the build environment. Skip for _test,
9797
# since the board is manipulated as each unit test is executed.
98-
if not result and build_env != "linux_native_test":
98+
if not result and not build_env.endswith("_native_test"):
9999
err = "Error: Build environment '%s' is incompatible with %s. Use one of these environments: %s" % \
100100
( build_env, motherboard, ", ".join([ e[4:] for e in board_envs if e.startswith("env:") ]) )
101101
raise SystemExit(err)

0 commit comments

Comments
Β (0)