From 80bef160fcb3c2c63f11c71832c9afd959a1828c Mon Sep 17 00:00:00 2001 From: Cody McGinnis Date: Fri, 28 Aug 2020 16:28:49 -0400 Subject: [PATCH] feat(tests): allow tests to be marked as pending pending tests will not fail the build --- app/run-test.sh | 9 ++++++++- app/tests/momentary-layer/early-key-release/pending | 0 app/tests/toggle-layer/early-key-release/pending | 0 3 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 app/tests/momentary-layer/early-key-release/pending create mode 100644 app/tests/toggle-layer/early-key-release/pending diff --git a/app/run-test.sh b/app/run-test.sh index 53277ba5..be335c62 100755 --- a/app/run-test.sh +++ b/app/run-test.sh @@ -26,8 +26,15 @@ else ./build/$testcase/zephyr/zmk.exe | sed -e "s/.*> //" | tee build/$testcase/keycode_events_full.log | sed -n -f $testcase/events.patterns > build/$testcase/keycode_events.log diff -au $testcase/keycode_events.snapshot build/$testcase/keycode_events.log if [ $? -gt 0 ]; then - echo "FAIL: $testcase" >> ./build/tests/pass-fail.log + if [ -f $testcase/pending ]; then + echo "PEND: $testcase" >> ./build/tests/pass-fail.log + exit 0 + else + echo "FAIL: $testcase" >> ./build/tests/pass-fail.log + exit 1 + fi else echo "PASS: $testcase" >> ./build/tests/pass-fail.log + exit 0 fi fi \ No newline at end of file diff --git a/app/tests/momentary-layer/early-key-release/pending b/app/tests/momentary-layer/early-key-release/pending new file mode 100644 index 00000000..e69de29b diff --git a/app/tests/toggle-layer/early-key-release/pending b/app/tests/toggle-layer/early-key-release/pending new file mode 100644 index 00000000..e69de29b