From 2bb5ae3a89755c0522d4b0c332b25538114c9dfc Mon Sep 17 00:00:00 2001 From: Daniel Thompson Date: Fri, 4 Dec 2020 20:31:14 +0000 Subject: [PATCH] Makefile: Allow specific tests to be run Signed-off-by: Daniel Thompson --- Makefile | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 0a1a517..77618f9 100644 --- a/Makefile +++ b/Makefile @@ -98,9 +98,13 @@ sim: PYTHONDONTWRITEBYTECODE=1 PYTHONPATH=.:wasp/boards/simulator:wasp \ $(PYTHON) -i wasp/boards/simulator/main.py +ifeq ("$(origin K)", "command line") + PYTEST_RESTRICT = -k '$(K)' +endif + check: PYTHONDONTWRITEBYTECODE=1 PYTHONPATH=.:wasp/boards/simulator:wasp \ - $(PYTEST) -v -W ignore wasp/boards/simulator + $(PYTEST) -v -W ignore $(PYTEST_RESTRICT) wasp/boards/simulator .PHONY: bootloader reloader docs micropython