From 886e14690b2a8ac0a0470d78023375bbad3713b1 Mon Sep 17 00:00:00 2001 From: bunsenstraat Date: Sun, 21 Nov 2021 15:42:43 +0100 Subject: [PATCH] mk test script --- apps/remix-ide-e2e/src/runtests.sh | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 apps/remix-ide-e2e/src/runtests.sh diff --git a/apps/remix-ide-e2e/src/runtests.sh b/apps/remix-ide-e2e/src/runtests.sh new file mode 100644 index 0000000000..3f7826e470 --- /dev/null +++ b/apps/remix-ide-e2e/src/runtests.sh @@ -0,0 +1,24 @@ + +#!/bin/bash +# Bash Menu Script Example + +PS3='Please enter your choice: ' +TESTFILES=( $(grep -IRiL "disabled" "dist/apps/remix-ide-e2e/src/tests" | grep "\.spec\|\.test" | sort ) ) + +declare -p TESTFILES +TESTFILES+=("list") +TESTFILES+=("exit") +select opt in "${TESTFILES[@]}" +do + if [ "$opt" = "exit" ]; then + break + fi + if [ "$opt" = "list" ]; then + for i in "${!TESTFILES[@]}"; do + printf "%s) %s\n" "$((i+1))" "${TESTFILES[$i]}" + done + else + # run the selected test + npm run build:e2e && nightwatch --config dist/apps/remix-ide-e2e/nightwatch.js $opt --env=chromeDesktop + fi +done \ No newline at end of file