From 46188077ef727c21513008f4e0c42e8cb211e90e Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Mon, 14 Mar 2022 08:47:58 +0100 Subject: main: rework CLI frontend - Change command line flags to be align better with those of other interpreters and with the gcc compiler, e.g. `-D` and `-U` to define and undefine globals, `-e` to execute script expression etc. - Pass only excess CLI arguments as `ARGV` to scripts, e.g. `ucode -e 'print("Hello world")' -- -x -y` would pass only `[ "-x", "-y" ]` as ARGV contents - Default to raw mode and introduce flag to enable template mode Signed-off-by: Jo-Philipp Wich --- tests/custom/run_tests.sh | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'tests/custom') diff --git a/tests/custom/run_tests.sh b/tests/custom/run_tests.sh index 2f13c3b..c2839df 100755 --- a/tests/custom/run_tests.sh +++ b/tests/custom/run_tests.sh @@ -93,10 +93,7 @@ run_testcase() { IFS=$' \t\n' - $ucode_bin $args -e '{ - "REQUIRE_SEARCH_PATH": [ "'"$ucode_lib"'/*.so" ], - "TESTFILES_PATH": "'"$dir"'/files" - }' -i - <"$in" >"$dir/res.out" 2>"$dir/res.err" + $ucode_bin -T -L "$ucode_lib/*.so" -D TESTFILES_PATH="$dir/files" $args - <"$in" >"$dir/res.out" 2>"$dir/res.err" ) printf "%d\n" $? > "$dir/res.code" -- cgit v1.2.3