diff --git a/Makesurefile b/Makesurefile index 0113fa3..90a3ed5 100644 --- a/Makesurefile +++ b/Makesurefile @@ -4,7 +4,7 @@ @define NEXT_VERSION '0.9.26' @define GOAWK_VERSION '1.31.0' # https://github.com/benhoyt/goawk/releases @define JUST_VERSION '1.3.0' # https://github.com/casey/just/releases -@define FHTAGN_VERSION 'v0.2.1' # https://github.com/xonixx/fhtagn/releases +@define FHTAGN_VERSION 'v0.3.0' # https://github.com/xonixx/fhtagn/releases @define MDBOOK_VERSION 'v0.5.2' # https://github.com/rust-lang/mdBook/releases @define MDBOOK_LINKCHECK_VERSION 'v0.7.7' # https://github.com/Michael-F-Bryan/mdbook-linkcheck/releases @define MDBOOKER_VERSION '11572b1' # https://github.com/xonixx/mdbooker/releases @@ -86,13 +86,14 @@ @lib testing run_tush_file() { local f="$1" + local MAKESURE="$2" [[ "$OSTYPE" == "linux-gnu"* ]] && [[ -d /dev/shm ]] && export TMPDIR="/dev/shm" if [[ "$f" == *"[wget]"* ]] && ! command -v wget >/dev/null then echo "TESTS SKIPPED: $f" - elif "$FHTAGN" "$f" + elif "$FHTAGN" "$f" MAKESURE="$MAKESURE" then echo "TESTS PASSED : $f" else @@ -119,7 +120,7 @@ awk_ver 'MAKESURE_AWK' "$MAKESURE_AWK" [[ $EXE_NAME == "gawk"* ]] && export MAKESURE_AWKLIBPATH="$(pwd)/soft/${EXE_NAME}_libs" [[ "$OSTYPE" == "linux-gnu"* ]] && [[ -d /dev/shm ]] && export TMPDIR="/dev/shm" - MAKESURE=makesure_dev ALL=1 "$FHTAGN" tests/*.tush + ALL=1 "$FHTAGN" tests/*.tush MAKESURE=makesure_dev # The idea of having this here (not using a named glob goal) is to be able # to run `./makesure tests/test.tush` instead of `./makesure tested@tests/test.tush` @@ -134,15 +135,13 @@ [[ -n $MAKESURE_AWK ]] && MAKESURE_AWK="$(realpath $MAKESURE_AWK)" export MAKESURE_AWK export MAKESURE_AWK_OPTS - MAKESURE=makesure_dev \ - run_tush_file "$ITEM" + run_tush_file "$ITEM" makesure_dev @goal tested_candidate @glob 'tests/*.tush' @private @depends_on tested @depends_on candidate_version_prepared @use_lib testing - MAKESURE=makesure_candidate \ - run_tush_file "$ITEM" + run_tush_file "$ITEM" makesure_candidate @define COVERPROFILE '/tmp/cov.txt' diff --git a/tests/0_basic.tush b/tests/0_basic.tush index 8f72528..a854286 100644 --- a/tests/0_basic.tush +++ b/tests/0_basic.tush @@ -1,14 +1,14 @@ -$ ./$MAKESURE -v | awk -v "v=$NEXT_VERSION" '{ sub(v,"XXX") } 1' +$ ./{{MAKESURE}} -v | awk -v "v=$NEXT_VERSION" '{ sub(v,"XXX") } 1' | XXX -$ ./$MAKESURE --version | awk -v "v=$NEXT_VERSION" '{ sub(v,"XXX") } 1' +$ ./{{MAKESURE}} --version | awk -v "v=$NEXT_VERSION" '{ sub(v,"XXX") } 1' | XXX -$ cd "tests/emptydir"; ../../$MAKESURE -v | awk -v "v=$NEXT_VERSION" '{ sub(v,"XXX") } 1' +$ cd "tests/emptydir"; ../../{{MAKESURE}} -v | awk -v "v=$NEXT_VERSION" '{ sub(v,"XXX") } 1' | XXX -$ cd "tests/emptydir"; ../../$MAKESURE -h | awk -v "v=$NEXT_VERSION" '{ sub(v,"XXX") } 1' +$ cd "tests/emptydir"; ../../{{MAKESURE}} -h | awk -v "v=$NEXT_VERSION" '{ sub(v,"XXX") } 1' | makesure ver. XXX | Usage: makesure [options...] [-f buildfile] [goals...] | -f,--file buildfile @@ -25,14 +25,14 @@ $ cd "tests/emptydir"; ../../$MAKESURE -h | awk -v "v=$NEXT_VERSION" '{ sub(v,"X | -h,--help print help and exit | -U,--selfupdate update makesure to latest version -$ ./$MAKESURE -f non-existent-file +$ ./{{MAKESURE}} -f non-existent-file @ makesure file not found: non-existent-file ? 1 -$ cd "tests/emptydir"; ../../$MAKESURE +$ cd "tests/emptydir"; ../../{{MAKESURE}} @ makesure file not found: Makesurefile ? 1 -$ ./$MAKESURE -f tests/dir +$ ./{{MAKESURE}} -f tests/dir | goal 'default' ... | test diff --git a/tests/10_define.tush b/tests/10_define.tush index fc66b8b..84f521b 100644 --- a/tests/10_define.tush +++ b/tests/10_define.tush @@ -1,29 +1,29 @@ -$ ./$MAKESURE -f tests/10_define.sh testA +$ ./{{MAKESURE}} -f tests/10_define.sh testA | goal 'testA' ... | A=aaa -$ ./$MAKESURE -f tests/10_define.sh testA -D A="val with spaces\"'" +$ ./{{MAKESURE}} -f tests/10_define.sh testA -D A="val with spaces\"'" | goal 'testA' ... | A=val with spaces"' -$ ./$MAKESURE -f tests/10_define.sh testB +$ ./{{MAKESURE}} -f tests/10_define.sh testB | goal 'testB' ... | B=aaabbb -$ ./$MAKESURE -f tests/10_define.sh -D B=xxx testB +$ ./{{MAKESURE}} -f tests/10_define.sh -D B=xxx testB | goal 'testB' ... | B=xxx -$ ./$MAKESURE -f tests/10_define.sh -D A=yyy testB +$ ./{{MAKESURE}} -f tests/10_define.sh -D A=yyy testB | goal 'testB' ... | B=yyybbb -$ ./$MAKESURE -f tests/10_define.sh testC +$ ./{{MAKESURE}} -f tests/10_define.sh testC | goal 'testC' ... | C= -$ ./$MAKESURE -f tests/10_define.sh testABC +$ ./{{MAKESURE}} -f tests/10_define.sh testABC | goal 'testA' ... | A=aaa | goal 'testB' ... @@ -32,7 +32,7 @@ $ ./$MAKESURE -f tests/10_define.sh testABC | C= | goal 'testABC' [empty]. -$ ./$MAKESURE -f tests/10_define.sh testABC --define A=111 -D "B=222" --define 'C=333' +$ ./{{MAKESURE}} -f tests/10_define.sh testABC --define A=111 -D "B=222" --define 'C=333' | goal 'testA' ... | A=111 | goal 'testB' ... @@ -41,13 +41,13 @@ $ ./$MAKESURE -f tests/10_define.sh testABC --define A=111 -D "B=222" --define ' | C=333 | goal 'testABC' [empty]. -$ ./$MAKESURE -f tests/10_define.sh must_be_reached1 +$ ./{{MAKESURE}} -f tests/10_define.sh must_be_reached1 | goal 'must_be_reached1' [already satisfied]. -$ ./$MAKESURE -f tests/10_define.sh must_be_reached2 +$ ./{{MAKESURE}} -f tests/10_define.sh must_be_reached2 | goal 'must_be_reached2' [already satisfied]. -$ ./$MAKESURE -f tests/10_define.sh children_reached_or_not +$ ./{{MAKESURE}} -f tests/10_define.sh children_reached_or_not | goal 'must_be_reached1' [already satisfied]. | goal 'must_be_reached2' [already satisfied]. | goal 'other_goal_2' ... @@ -56,31 +56,31 @@ $ ./$MAKESURE -f tests/10_define.sh children_reached_or_not | should show | goal 'children_reached_or_not' [empty]. -$ ./$MAKESURE -f tests/10_define.sh is_not_reached +$ ./{{MAKESURE}} -f tests/10_define.sh is_not_reached | goal 'other_goal_2' ... | other goal 2 | goal 'is_not_reached' ... | should show -$ ./$MAKESURE -f tests/10_define.sh children_reached_or_not -d +$ ./{{MAKESURE}} -f tests/10_define.sh children_reached_or_not -d | Resolved goals to reach for 'children_reached_or_not': | other_goal_2 | is_not_reached -$ ./$MAKESURE -f tests/10_define.sh test_commented_define +$ ./{{MAKESURE}} -f tests/10_define.sh test_commented_define | goal 'test_commented_define' ... | in goal: value | in child process: value -$ ./$MAKESURE -f tests/10_define.sh echo +$ ./{{MAKESURE}} -f tests/10_define.sh echo | goal 'echo' ... | Hello -$ ./$MAKESURE -f tests/10_define_in_goal.sh +$ ./{{MAKESURE}} -f tests/10_define_in_goal.sh @ Shell code is not allowed outside goals/libs: @ tests/10_define_in_goal.sh:4: echo "$0" ? 1 -$ ./$MAKESURE -f tests/10_define_issue_142.sh issue142 +$ ./{{MAKESURE}} -f tests/10_define_issue_142.sh issue142 | goal 'issue142' ... | a b diff --git a/tests/11_goal_glob.tush b/tests/11_goal_glob.tush index 7e9ad4a..bb02131 100644 --- a/tests/11_goal_glob.tush +++ b/tests/11_goal_glob.tush @@ -1,5 +1,5 @@ -$ ./$MAKESURE -f tests/11_goal_glob.sh -l +$ ./{{MAKESURE}} -f tests/11_goal_glob.sh -l | Available goals: | 'glob/file*.txt' : test goal_glob | 'non-existent-glob*' @@ -7,7 +7,7 @@ $ ./$MAKESURE -f tests/11_goal_glob.sh -l | test2 | glob_goal_name -$ ./$MAKESURE -f tests/11_goal_glob.sh -la +$ ./{{MAKESURE}} -f tests/11_goal_glob.sh -la | Available goals: | glob/file_1.txt : test goal_glob | glob/file_2.txt : test goal_glob @@ -23,13 +23,13 @@ $ ./$MAKESURE -f tests/11_goal_glob.sh -la | glob_goal_name@glob/file_10.txt | glob_goal_name -$ ./$MAKESURE -f tests/11_goal_glob.sh -d 'glob/file*.txt' +$ ./{{MAKESURE}} -f tests/11_goal_glob.sh -d 'glob/file*.txt' | Resolved goals to reach for 'glob/file*.txt': | glob/file_1.txt | glob/file_3.txt | glob/file_10.txt -$ ./$MAKESURE -f tests/11_goal_glob.sh test1 +$ ./{{MAKESURE}} -f tests/11_goal_glob.sh test1 | goal 'glob/file_1.txt' ... | glob/file_1.txt :: 0 :: 4 | content 111 @@ -39,14 +39,14 @@ $ ./$MAKESURE -f tests/11_goal_glob.sh test1 | content 333 | goal 'test1' [empty]. -$ ./$MAKESURE -f tests/11_goal_glob.sh test2 +$ ./{{MAKESURE}} -f tests/11_goal_glob.sh test2 | goal 'glob_goal_name@glob/file_2.txt' ... | glob_goal_name ::: glob/file_2.txt :: 1 :: 4 | goal 'glob_goal_name@glob/file_3.txt' ... | glob_goal_name ::: glob/file_3.txt :: 2 :: 4 | goal 'test2' [empty]. -$ ./$MAKESURE -f tests/11_goal_glob.sh glob_goal_name +$ ./{{MAKESURE}} -f tests/11_goal_glob.sh glob_goal_name | goal 'glob_goal_name@glob/file_1.txt' ... | glob_goal_name ::: glob/file_1.txt :: 0 :: 4 | goal 'glob_goal_name@glob/file_2.txt' ... @@ -57,7 +57,7 @@ $ ./$MAKESURE -f tests/11_goal_glob.sh glob_goal_name | glob_goal_name ::: glob/file_10.txt :: 3 :: 4 | goal 'glob_goal_name' [empty]. -$ ./$MAKESURE -f tests/11_goal_glob_lib.sh 'glob/file*.txt' +$ ./{{MAKESURE}} -f tests/11_goal_glob_lib.sh 'glob/file*.txt' | goal 'glob/file_1.txt' ... | Unnamed lib ::: glob/file_1.txt :: 0 :: 4 | @glob ::: glob/file_1.txt :: 0 :: 4 @@ -72,7 +72,7 @@ $ ./$MAKESURE -f tests/11_goal_glob_lib.sh 'glob/file*.txt' | @glob ::: glob/file_10.txt :: 3 :: 4 | goal 'glob/file*.txt' [empty]. -$ ./$MAKESURE -f tests/11_goal_glob_lib.sh glob_goal_name +$ ./{{MAKESURE}} -f tests/11_goal_glob_lib.sh glob_goal_name | goal 'glob_goal_name@glob/file_1.txt' ... | lib lib_name ::: glob/file_1.txt :: 0 :: 4 | glob_goal_name ::: glob/file_1.txt :: 0 :: 4 diff --git a/tests/12_errors.tush b/tests/12_errors.tush index dc597dc..d580f58 100644 --- a/tests/12_errors.tush +++ b/tests/12_errors.tush @@ -1,5 +1,5 @@ -$ ./$MAKESURE -f tests/12_errors.sh +$ ./{{MAKESURE}} -f tests/12_errors.sh @ Shell code is not allowed outside goals/libs: @ tests/12_errors.sh:2: echo 'code in prelude' @ Only use @reached_if in @goal: diff --git a/tests/13_doc.tush b/tests/13_doc.tush index 55dae08..b66f976 100644 --- a/tests/13_doc.tush +++ b/tests/13_doc.tush @@ -1,16 +1,16 @@ -$ ./$MAKESURE -f tests/13_doc_multi1.sh +$ ./{{MAKESURE}} -f tests/13_doc_multi1.sh @ Multiple @doc not allowed for a goal: @ tests/13_doc_multi1.sh:4: @doc d2 ? 1 -$ ./$MAKESURE -f tests/13_doc_multi2.sh -l +$ ./{{MAKESURE}} -f tests/13_doc_multi2.sh -l @ Multiple @doc not allowed for a goal: @ tests/13_doc_multi2.sh:4: @doc d2 ? 1 -$ ./$MAKESURE -f tests/13_doc.sh -l +$ ./{{MAKESURE}} -f tests/13_doc.sh -l | Available goals: | a : doc for a | b : doc for b diff --git a/tests/14_private.tush b/tests/14_private.tush index b754075..bbc474a 100644 --- a/tests/14_private.tush +++ b/tests/14_private.tush @@ -1,11 +1,11 @@ -$ ./$MAKESURE -f tests/14_private.sh -l +$ ./{{MAKESURE}} -f tests/14_private.sh -l | Available goals: | a | 14_private.sh -$ ./$MAKESURE -f tests/14_private.sh --list-all +$ ./{{MAKESURE}} -f tests/14_private.sh --list-all | Available goals: | a | b diff --git a/tests/15_lib.tush b/tests/15_lib.tush index 1bd68dd..0c4226c 100644 --- a/tests/15_lib.tush +++ b/tests/15_lib.tush @@ -1,28 +1,28 @@ -$ ./$MAKESURE -f tests/15_lib.sh -l +$ ./{{MAKESURE}} -f tests/15_lib.sh -l | Available goals: | g1 | g2 | g3 | g4 -$ ./$MAKESURE -f tests/15_lib.sh g1 +$ ./{{MAKESURE}} -f tests/15_lib.sh g1 | goal 'g1' ... | Hello World -$ ./$MAKESURE -f tests/15_lib.sh g2 +$ ./{{MAKESURE}} -f tests/15_lib.sh g2 | goal 'g2' ... | Hello lib_name World -$ ./$MAKESURE -f tests/15_lib.sh g3 +$ ./{{MAKESURE}} -f tests/15_lib.sh g3 | goal 'g3' [already satisfied]. -$ ./$MAKESURE -f tests/15_lib.sh g4 +$ ./{{MAKESURE}} -f tests/15_lib.sh g4 | goal 'g4' ... | Should see this -$ ./$MAKESURE -f tests/15_lib_unknown.sh g3 +$ ./{{MAKESURE}} -f tests/15_lib_unknown.sh g3 @ Goal 'g3' uses unknown lib 'unknown': @ tests/15_lib_unknown.sh:3: @use_lib unknown ? 1 diff --git a/tests/16_define_validation.tush b/tests/16_define_validation.tush index 8f6c35f..1a67c7f 100644 --- a/tests/16_define_validation.tush +++ b/tests/16_define_validation.tush @@ -1,5 +1,5 @@ -$ ./$MAKESURE -f tests/16_define_validation_pass.sh +$ ./{{MAKESURE}} -f tests/16_define_validation_pass.sh | goal 'default' ... | EMPTY= | EMPTY1= @@ -31,7 +31,7 @@ $ ./$MAKESURE -f tests/16_define_validation_pass.sh | LC1=aaabbb bbbcc'c cc'ca b ceee eee | IL5=a-b -$ ./$MAKESURE -f tests/16_define_validation_error.sh +$ ./{{MAKESURE}} -f tests/16_define_validation_error.sh @ Invalid @define syntax, should be @define VAR_NAME 'value': @ tests/16_define_validation_error.sh:2: @define echo @ Syntax error: wrong unquoted: 'echo;': diff --git a/tests/17_empty_prelude.tush b/tests/17_empty_prelude.tush index eea2f6f..edf46c0 100644 --- a/tests/17_empty_prelude.tush +++ b/tests/17_empty_prelude.tush @@ -1,5 +1,5 @@ -$ PATH=tests/wrapper/bash:$PATH ./$MAKESURE -f tests/17_empty_prelude.sh +$ PATH=tests/wrapper/bash:$PATH ./{{MAKESURE}} -f tests/17_empty_prelude.sh | goal 'default' ... | running bash | hello diff --git a/tests/18_vars_priority.tush b/tests/18_vars_priority.tush index fc986d6..f3d7982 100644 --- a/tests/18_vars_priority.tush +++ b/tests/18_vars_priority.tush @@ -1,47 +1,47 @@ -$ ./$MAKESURE -f tests/18_vars_priority.sh +$ ./{{MAKESURE}} -f tests/18_vars_priority.sh | goal 'default' ... | A= | V=V_prelude | in child: A= | in child: V=V_prelude -$ A=A_env ./$MAKESURE -f tests/18_vars_priority.sh +$ A=A_env ./{{MAKESURE}} -f tests/18_vars_priority.sh | goal 'default' ... | A=A_env | V=V_prelude | in child: A=A_env | in child: V=V_prelude -$ V=V_env ./$MAKESURE -f tests/18_vars_priority.sh +$ V=V_env ./{{MAKESURE}} -f tests/18_vars_priority.sh | goal 'default' ... | A= | V=V_prelude | in child: A= | in child: V=V_prelude -$ ./$MAKESURE -f tests/18_vars_priority.sh -D V=V_D +$ ./{{MAKESURE}} -f tests/18_vars_priority.sh -D V=V_D | goal 'default' ... | A= | V=V_D | in child: A= | in child: V=V_D -$ V=V_env ./$MAKESURE -f tests/18_vars_priority.sh -D V=V_D +$ V=V_env ./{{MAKESURE}} -f tests/18_vars_priority.sh -D V=V_D | goal 'default' ... | A= | V=V_D | in child: A= | in child: V=V_D -$ ./$MAKESURE -f tests/18_vars_priority.sh g +$ ./{{MAKESURE}} -f tests/18_vars_priority.sh g | goal 'g' ... | E=defaultVal -$ E=fromEnv ./$MAKESURE -f tests/18_vars_priority.sh g +$ E=fromEnv ./{{MAKESURE}} -f tests/18_vars_priority.sh g | goal 'g' ... | E=fromEnv -$ E=fromEnv ./$MAKESURE -f tests/18_vars_priority.sh -D E=fromD g +$ E=fromEnv ./{{MAKESURE}} -f tests/18_vars_priority.sh -D E=fromD g | goal 'g' ... | E=fromD diff --git a/tests/19_optimize_goals.tush b/tests/19_optimize_goals.tush index b0d2632..766987c 100644 --- a/tests/19_optimize_goals.tush +++ b/tests/19_optimize_goals.tush @@ -1,5 +1,5 @@ -$ PATH=tests/wrapper/bash:$PATH ./$MAKESURE -f tests/19_optimize_goals.sh hello_empty +$ PATH=tests/wrapper/bash:$PATH ./{{MAKESURE}} -f tests/19_optimize_goals.sh hello_empty | goal 'hello' ... | running bash | Hello world diff --git a/tests/1_goals.tush b/tests/1_goals.tush index a8dfeb8..ed7864f 100644 --- a/tests/1_goals.tush +++ b/tests/1_goals.tush @@ -1,5 +1,5 @@ -$ ./$MAKESURE -f tests/1_goals.sh +$ ./{{MAKESURE}} -f tests/1_goals.sh | goal 'ddd' ... | ddd | goal 'ccc' ... @@ -10,19 +10,19 @@ $ ./$MAKESURE -f tests/1_goals.sh | aaa | goal 'default' [empty]. -$ ./$MAKESURE -f tests/1_goals.sh -s +$ ./{{MAKESURE}} -f tests/1_goals.sh -s | ddd | ccc | bbb | aaa -$ ./$MAKESURE -f tests/1_goals.sh --silent +$ ./{{MAKESURE}} -f tests/1_goals.sh --silent | ddd | ccc | bbb | aaa -$ ./$MAKESURE -f tests/1_goals.sh -l +$ ./{{MAKESURE}} -f tests/1_goals.sh -l | Available goals: | default | aaa : Documenatation for aaa @@ -33,50 +33,50 @@ $ ./$MAKESURE -f tests/1_goals.sh -l | fail123 | good-name -$ ./$MAKESURE -f tests/1_goals.sh -d +$ ./{{MAKESURE}} -f tests/1_goals.sh -d | Resolved goals to reach for 'default': | ddd | ccc | bbb | aaa -$ ./$MAKESURE -f tests/1_goals.sh fail +$ ./{{MAKESURE}} -f tests/1_goals.sh fail | goal 'fail' ... | stdout | goal 'fail' failed @ stderr ? 1 -$ ./$MAKESURE -f tests/1_goals.sh fail123 +$ ./{{MAKESURE}} -f tests/1_goals.sh fail123 | goal 'fail123' ... | stdout | goal 'fail123' failed @ stderr ? 123 -$ ./$MAKESURE -f tests/1_goals_unknown.sh +$ ./{{MAKESURE}} -f tests/1_goals_unknown.sh @ Goal 'a' has unknown dependency 'unknown': @ tests/1_goals_unknown.sh:3: @depends_on unknown ? 1 -$ ./$MAKESURE -f tests/1_goals.sh zzz +$ ./{{MAKESURE}} -f tests/1_goals.sh zzz @ Goal not found: zzz ? 1 -$ ./$MAKESURE -f tests/1_goals_already_defined.sh +$ ./{{MAKESURE}} -f tests/1_goals_already_defined.sh @ Goal 'a' is already defined: @ tests/1_goals_already_defined.sh:5: @goal a ? 1 -$ ./$MAKESURE -f tests/1_goals_no_name.sh +$ ./{{MAKESURE}} -f tests/1_goals_no_name.sh @ Goal must have a name: @ tests/1_goals_no_name.sh:5: @goal ? 1 -$ ./$MAKESURE -f tests/1_goals_multi_reached_if.sh +$ ./{{MAKESURE}} -f tests/1_goals_multi_reached_if.sh @ Multiple @reached_if not allowed for a goal: @ tests/1_goals_multi_reached_if.sh:4: @reached_if false ? 1 -$ ./$MAKESURE -f tests/1_empty.sh -l +$ ./{{MAKESURE}} -f tests/1_empty.sh -l | Available goals: diff --git a/tests/200_update.tush b/tests/200_update.tush index 6fdde23..afb4aa5 100644 --- a/tests/200_update.tush +++ b/tests/200_update.tush @@ -1,5 +1,5 @@ -$ { ./$MAKESURE -f tests/200_update.sh test_err; echo 'exit_code '$?; } | awk '/^exit_code/ { exit $2 } { gsub(/[0-9][0-9.]+/,"VER") } 1' +$ { MAKESURE={{MAKESURE}} ./{{MAKESURE}} -f tests/200_update.sh test_err; echo 'exit_code '$?; } | awk '/^exit_code/ { exit $2 } { gsub(/[0-9][0-9.]+/,"VER") } 1' | goal 'env_prepared' ... | goal 'test_err' ... | VER @@ -9,7 +9,7 @@ $ { ./$MAKESURE -f tests/200_update.sh test_err; echo 'exit_code '$?; } | awk '/ @ Please use manual update: https://makesure.dev/Installation.html ? 1 -$ ./$MAKESURE -f tests/200_update.sh test_curl | awk '{ gsub(/[0-9][0-9.]+/,"VER") } 1' +$ MAKESURE={{MAKESURE}} ./{{MAKESURE}} -f tests/200_update.sh test_curl | awk '{ gsub(/[0-9][0-9.]+/,"VER") } 1' | goal 'env_prepared' ... | goal 'curl_prepared' ... | goal 'test_curl' ... diff --git a/tests/201_update_[wget].tush b/tests/201_update_[wget].tush index 151d490..62c289d 100644 --- a/tests/201_update_[wget].tush +++ b/tests/201_update_[wget].tush @@ -1,5 +1,5 @@ -$ ./$MAKESURE -f tests/200_update.sh test_wget | awk '{ gsub(/[0-9][0-9.]+/,"VER") } 1' +$ MAKESURE={{MAKESURE}} ./{{MAKESURE}} -f tests/200_update.sh test_wget | awk '{ gsub(/[0-9][0-9.]+/,"VER") } 1' | goal 'env_prepared' ... | goal 'wget_prepared' ... | goal 'test_wget' ... diff --git a/tests/20_list_goals.tush b/tests/20_list_goals.tush index 32c9c81..9ebf91e 100644 --- a/tests/20_list_goals.tush +++ b/tests/20_list_goals.tush @@ -1,5 +1,5 @@ -$ ./$MAKESURE -f tests/20_list_goals.sh -l +$ ./{{MAKESURE}} -f tests/20_list_goals.sh -l | Available goals: | aaa : some description | other_goal : do something important @@ -8,7 +8,7 @@ $ ./$MAKESURE -f tests/20_list_goals.sh -l | yet_another_goal_looooooooooooooooooong : do something even more important | hello -$ ./$MAKESURE -f tests/20_list_goals.sh -la +$ ./{{MAKESURE}} -f tests/20_list_goals.sh -la | Available goals: | aaa : some description | other_goal : do something important diff --git a/tests/21_parsing.tush b/tests/21_parsing.tush index e8502c1..8209580 100644 --- a/tests/21_parsing.tush +++ b/tests/21_parsing.tush @@ -1,5 +1,5 @@ -$ ./$MAKESURE -f tests/21_parsing_spaces.sh -la +$ ./{{MAKESURE}} -f tests/21_parsing_spaces.sh -la | Available goals: | $'21_parsing \'.txt' | '21_parsing 1.txt' @@ -16,35 +16,35 @@ $ ./$MAKESURE -f tests/21_parsing_spaces.sh -la | test3 | test4 -$ ./$MAKESURE -f tests/21_parsing_spaces.sh test2 +$ ./{{MAKESURE}} -f tests/21_parsing_spaces.sh test2 | goal '21_parsing 2.txt' ... | 21_parsing 2.txt | 2 | goal 'test2' [empty]. -$ ./$MAKESURE -f tests/21_parsing_spaces.sh test3 +$ ./{{MAKESURE}} -f tests/21_parsing_spaces.sh test3 | goal 'g1@21_parsing 2.txt' ... | 21_parsing 2.txt | 2 | goal 'test3' [empty]. -$ ./$MAKESURE -f tests/21_parsing_spaces.sh test4 +$ ./{{MAKESURE}} -f tests/21_parsing_spaces.sh test4 | goal 'g2@21_parsing 2.txt' ... | 21_parsing 2.txt | 2 | goal 'test4' [empty]. -$ ./$MAKESURE -f tests/21_parsing_comments.sh -la +$ ./{{MAKESURE}} -f tests/21_parsing_comments.sh -la | Available goals: | goal_with_comment : doc with comment | test1 : doc with comment -$ ./$MAKESURE -f tests/21_parsing_comments.sh test1 +$ ./{{MAKESURE}} -f tests/21_parsing_comments.sh test1 | goal 'goal_with_comment' ... | goal_with_comment | goal 'test1' [empty]. -$ ./$MAKESURE -f tests/21_parsing_quoting.sh -l +$ ./{{MAKESURE}} -f tests/21_parsing_quoting.sh -l | Available goals: | no_space : no_space | 'name with spaces' : name with spaces @@ -54,19 +54,19 @@ $ ./$MAKESURE -f tests/21_parsing_quoting.sh -l | 'goal&c' | default -$ ./$MAKESURE -f tests/21_parsing_quoting.sh -d +$ ./{{MAKESURE}} -f tests/21_parsing_quoting.sh -d | Resolved goals to reach for 'default': | no_space | 'name with spaces' | $'name with \' quote' -$ bash -c "./$MAKESURE -f tests/21_parsing_quoting.sh -d default $'name with \' quote' 'goal|a'" +$ bash -c "./{{MAKESURE}} -f tests/21_parsing_quoting.sh -d default $'name with \' quote' 'goal|a'" | Resolved goals to reach for 'default' $'name with \' quote' 'goal|a': | no_space | 'name with spaces' | $'name with \' quote' -$ ./$MAKESURE -f tests/21_parsing_quoting.sh +$ ./{{MAKESURE}} -f tests/21_parsing_quoting.sh | goal 'no_space' ... | no_space | goal 'name with spaces' ... @@ -78,12 +78,12 @@ $ ./$MAKESURE -f tests/21_parsing_quoting.sh | goal 'goal&c' [empty]. | goal 'default' [empty]. -$ ./$MAKESURE -f tests/21_parsing_err1.sh +$ ./{{MAKESURE}} -f tests/21_parsing_err1.sh @ Syntax error: unterminated argument: @ tests/21_parsing_err1.sh:3: @goal 'goal name ? 1 -$ ./$MAKESURE -f tests/21_parsing_err2.sh +$ ./{{MAKESURE}} -f tests/21_parsing_err2.sh @ Syntax error: wrong unquoted: 'doc'text': @ tests/21_parsing_err2.sh:4: @doc doc'text ? 1 diff --git a/tests/22_nat_order.tush b/tests/22_nat_order.tush index 7471020..bccb543 100644 --- a/tests/22_nat_order.tush +++ b/tests/22_nat_order.tush @@ -1,5 +1,5 @@ -$ ./$MAKESURE -f tests/22_nat_order.sh nat_order_test +$ ./{{MAKESURE}} -f tests/22_nat_order.sh nat_order_test | 0_basic.tush | 1_goals.tush | 2_mydir.tush @@ -23,7 +23,7 @@ $ ./$MAKESURE -f tests/22_nat_order.sh nat_order_test | 20_list_goals.tush | 21_parsing.tush -$ ./$MAKESURE -f tests/22_nat_order nat_order_test +$ ./{{MAKESURE}} -f tests/22_nat_order nat_order_test | ../0_basic.tush | ../1_goals.tush | ../2_mydir.tush diff --git a/tests/23_bash_glob.tush b/tests/23_bash_glob.tush index 4f16ef8..859bce4 100644 --- a/tests/23_bash_glob.tush +++ b/tests/23_bash_glob.tush @@ -1,5 +1,5 @@ -$ ./$MAKESURE -f tests/23_bash_glob.sh g1 +$ ./{{MAKESURE}} -f tests/23_bash_glob.sh g1 | goal 'g1@1_goals.tush' ... | 0 -> 1_goals.tush | goal 'g1@2_mydir.tush' ... diff --git a/tests/24_define_everywhere.tush b/tests/24_define_everywhere.tush index 0f3cd5f..7d79050 100644 --- a/tests/24_define_everywhere.tush +++ b/tests/24_define_everywhere.tush @@ -1,11 +1,11 @@ -$ ./$MAKESURE -f tests/24_define_everywhere.sh +$ ./{{MAKESURE}} -f tests/24_define_everywhere.sh | goal 'default' ... | a | ab | abc -$ ./$MAKESURE -f tests/24_define_everywhere.sh -D B=bbb +$ ./{{MAKESURE}} -f tests/24_define_everywhere.sh -D B=bbb | goal 'default' ... | a | bbb diff --git a/tests/25_lazy_reached_if.tush b/tests/25_lazy_reached_if.tush index f8b634a..58855a1 100644 --- a/tests/25_lazy_reached_if.tush +++ b/tests/25_lazy_reached_if.tush @@ -1,29 +1,29 @@ -$ ./$MAKESURE -f tests/25_lazy_reached_if_loop.sh a +$ ./{{MAKESURE}} -f tests/25_lazy_reached_if_loop.sh a @ There is a loop in goal dependencies via a -> b ? 1 -$ ./$MAKESURE -f tests/25_lazy_reached_if_loop.sh b +$ ./{{MAKESURE}} -f tests/25_lazy_reached_if_loop.sh b @ There is a loop in goal dependencies via a -> b ? 1 -$ ./$MAKESURE -f tests/25_lazy_reached_if.sh a +$ ./{{MAKESURE}} -f tests/25_lazy_reached_if.sh a | reached_if@a | reached_if@b | goal 'b' [already satisfied]. | goal 'a' ... | a -$ ./$MAKESURE -f tests/25_lazy_reached_if.sh b +$ ./{{MAKESURE}} -f tests/25_lazy_reached_if.sh b | reached_if@b | goal 'b' [already satisfied]. -$ ./$MAKESURE -f tests/25_lazy_reached_if.sh c +$ ./{{MAKESURE}} -f tests/25_lazy_reached_if.sh c | reached_if@c | goal 'c' ... | c -$ ./$MAKESURE -f tests/25_lazy_reached_if.sh d +$ ./{{MAKESURE}} -f tests/25_lazy_reached_if.sh d | goal 'd' ... | d diff --git a/tests/26_resolved.tush b/tests/26_resolved.tush index 5a2abbf..d863859 100644 --- a/tests/26_resolved.tush +++ b/tests/26_resolved.tush @@ -1,23 +1,23 @@ -$ ./$MAKESURE -f tests/26_resolved.sh --resolved a +$ ./{{MAKESURE}} -f tests/26_resolved.sh --resolved a | Resolved goals to reach for 'a': | b | c | a -$ ./$MAKESURE -f tests/26_resolved.sh -D REACHED=c --resolved a +$ ./{{MAKESURE}} -f tests/26_resolved.sh -D REACHED=c --resolved a | Resolved goals to reach for 'a': | b | a -$ ./$MAKESURE -f tests/26_resolved.sh -D REACHED=b --resolved a +$ ./{{MAKESURE}} -f tests/26_resolved.sh -D REACHED=b --resolved a | Resolved goals to reach for 'a': | c | a -$ ./$MAKESURE -f tests/26_resolved.sh -D REACHED=bc --resolved a +$ ./{{MAKESURE}} -f tests/26_resolved.sh -D REACHED=bc --resolved a | Resolved goals to reach for 'a': | a -$ ./$MAKESURE -f tests/26_resolved.sh -D REACHED=a --resolved a +$ ./{{MAKESURE}} -f tests/26_resolved.sh -D REACHED=a --resolved a | Resolved goals to reach for 'a': diff --git a/tests/27_parameterized_goals.tush b/tests/27_parameterized_goals.tush index 3a6e6af..18904c7 100644 --- a/tests/27_parameterized_goals.tush +++ b/tests/27_parameterized_goals.tush @@ -1,96 +1,96 @@ -$ ./$MAKESURE -f tests/27_parameterized_goals_1.sh -l +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_1.sh -l | Available goals: | a | b@hello -$ ./$MAKESURE -f tests/27_parameterized_goals_1.sh -la +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_1.sh -la | Available goals: | a | b@hello -$ ./$MAKESURE -f tests/27_parameterized_goals_1.sh -d a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_1.sh -d a | Resolved goals to reach for 'a': | b@hello -$ ./$MAKESURE -f tests/27_parameterized_goals_1.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_1.sh a | goal 'b@hello' ... | hello world | goal 'a' [empty]. -$ ./$MAKESURE -f tests/27_parameterized_goals_1_1.sh -l +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_1_1.sh -l | Available goals: | e | f | b@hello -$ ./$MAKESURE -f tests/27_parameterized_goals_1_1.sh -d e +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_1_1.sh -d e | Resolved goals to reach for 'e': | b@hello -$ ./$MAKESURE -f tests/27_parameterized_goals_1_1.sh e +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_1_1.sh e | goal 'b@hello' ... | hello world | goal 'f' [empty]. | goal 'e' [empty]. -$ ./$MAKESURE -f tests/27_parameterized_goals_2.sh -l +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_2.sh -l | Available goals: | a : doc a | c@hello : doc c -$ ./$MAKESURE -f tests/27_parameterized_goals_2.sh -la +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_2.sh -la | Available goals: | a : doc a | b@hello : doc b | c@hello : doc c -$ ./$MAKESURE -f tests/27_parameterized_goals_2.sh -d a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_2.sh -d a | Resolved goals to reach for 'a': | c@hello | b@hello -$ ./$MAKESURE -f tests/27_parameterized_goals_2.sh -d b@hello +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_2.sh -d b@hello | Resolved goals to reach for 'b@hello': | c@hello | b@hello -$ ./$MAKESURE -f tests/27_parameterized_goals_2.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_2.sh a | goal 'c@hello' ... | hello world from c | goal 'b@hello' ... | hello world from b | goal 'a' [empty]. -$ ./$MAKESURE -f tests/27_parameterized_goals_2.sh b@hello +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_2.sh b@hello | goal 'c@hello' ... | hello world from c | goal 'b@hello' ... | hello world from b -$ ./$MAKESURE -f tests/27_parameterized_goals_2.sh c@hello +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_2.sh c@hello | goal 'c@hello' ... | hello world from c -$ ./$MAKESURE -f tests/27_parameterized_goals_3.sh -l +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_3.sh -l | Available goals: | a | e | f | b@hello -$ ./$MAKESURE -f tests/27_parameterized_goals_3.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_3.sh a | goal 'b@hello' ... | hello world | goal 'a' [empty]. -$ ./$MAKESURE -f tests/27_parameterized_goals_3.sh e +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_3.sh e | goal 'b@hello' ... | hello world | goal 'f' [empty]. | goal 'e' [empty]. -$ ./$MAKESURE -f tests/27_parameterized_goals_4.sh -l +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_4.sh -l | Available goals: | a | e @@ -100,7 +100,7 @@ $ ./$MAKESURE -f tests/27_parameterized_goals_4.sh -l | 'b@hi hi hi' | b@salut -$ ./$MAKESURE -f tests/27_parameterized_goals_4.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_4.sh a | goal 'b@hello' ... | hello world | goal 'b@hi' ... @@ -111,11 +111,11 @@ $ ./$MAKESURE -f tests/27_parameterized_goals_4.sh a | salut world | goal 'a' [empty]. -$ ./$MAKESURE -f tests/27_parameterized_goals_4.sh 'b@hi hi hi' +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_4.sh 'b@hi hi hi' | goal 'b@hi hi hi' ... | hi hi hi world -$ ./$MAKESURE -f tests/27_parameterized_goals_4.sh e +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_4.sh e | goal 'b@hello' ... | hello world | goal 'b@hi' ... @@ -123,60 +123,60 @@ $ ./$MAKESURE -f tests/27_parameterized_goals_4.sh e | goal 'f' [empty]. | goal 'e' [empty]. -$ ./$MAKESURE -f tests/27_parameterized_goals_6_loop_err1.sh -l +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_6_loop_err1.sh -l @ There is a loop in goal dependencies via a -> c ? 1 -$ ./$MAKESURE -f tests/27_parameterized_goals_6_loop_err1.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_6_loop_err1.sh a @ There is a loop in goal dependencies via a -> c ? 1 -$ ./$MAKESURE -f tests/27_parameterized_goals_6_loop_err2.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_6_loop_err2.sh a @ There is a loop in goal dependencies via b -> c ? 1 -$ ./$MAKESURE -f tests/27_parameterized_goals_5_ok.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_5_ok.sh a | goal 'b@' ... | world from b | goal 'a' [empty]. -$ ./$MAKESURE -f tests/27_parameterized_goals_5_err1.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_5_err1.sh a @ wrong args count for 'b': @ tests/27_parameterized_goals_5_err1.sh:3: @depends_on b @args # err missing args ? 1 -$ ./$MAKESURE -f tests/27_parameterized_goals_5_err2.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_5_err2.sh a @ wrong args count for 'b': @ tests/27_parameterized_goals_5_err2.sh:3: @depends_on b # err missing args ? 1 -$ ./$MAKESURE -f tests/27_parameterized_goals_5_err3.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_5_err3.sh a @ wrong args count for 'b': @ tests/27_parameterized_goals_5_err3.sh:3: @depends_on b @args 'hello' 'hi' # err more args than params ? 1 -$ ./$MAKESURE -f tests/27_parameterized_goals_7_err1.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_7_err1.sh a @ wrong arg 'ARG1': @ tests/27_parameterized_goals_7_err1.sh:3: @depends_on b @args ARG1 # err unknown arg @ wrong arg 'ARG2': @ tests/27_parameterized_goals_7_err1.sh:8: @depends_on c @args ARG2 # err unknown arg ? 1 -$ ./$MAKESURE -f tests/27_parameterized_goals_8_err1.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_8_err1.sh a @ @args only allowed at position 3: @ tests/27_parameterized_goals_8_err1.sh:3: @depends_on c c @args 'hello' @ @args only allowed at position 3: @ tests/27_parameterized_goals_8_err1.sh:4: @depends_on @args 'hi' ? 1 -$ ./$MAKESURE -f tests/27_parameterized_goals_9.sh -l +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_9.sh -l | Available goals: | a | $'greet2@John@\'quoted\'' | greet@John | $'greet@\'quoted\'' -$ ./$MAKESURE -f tests/27_parameterized_goals_9.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_9.sh a | goal 'greet@John' ... | hello John | goal $'greet@\'quoted\'' ... @@ -184,14 +184,14 @@ $ ./$MAKESURE -f tests/27_parameterized_goals_9.sh a | goal $'greet2@John@\'quoted\'' [empty]. | goal 'a' [empty]. -$ ./$MAKESURE -f tests/27_parameterized_goals_9.sh 'greet2@John@'\''quoted'\' +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_9.sh 'greet2@John@'\''quoted'\' | goal 'greet@John' ... | hello John | goal $'greet@\'quoted\'' ... | hello 'quoted' | goal $'greet2@John@\'quoted\'' [empty]. -$ ./$MAKESURE -f tests/27_parameterized_goals_10_errors.sh -l +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_10_errors.sh -l @ missing parameters: @ tests/27_parameterized_goals_10_errors.sh:25: @goal f @params # zero params is invalid @ missing parameters: @@ -240,7 +240,7 @@ $ ./$MAKESURE -f tests/27_parameterized_goals_10_errors.sh -l @ tests/27_parameterized_goals_10_errors.sh:9: @depends_on e @args 'arg1' # err args for non-PG ? 1 -$ ./$MAKESURE -f tests/27_parameterized_goals_11_reached_if.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_11_reached_if.sh a | goal 'b@hi' ... | W is hi | goal 'b@hello' [already satisfied]. @@ -248,14 +248,14 @@ $ ./$MAKESURE -f tests/27_parameterized_goals_11_reached_if.sh a | W is salut | goal 'a' [empty]. -$ ./$MAKESURE -f tests/27_parameterized_goals_12_lib.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_12_lib.sh a | goal 'b@hi' ... | in lib W=hi | goal 'b@hello' ... | in lib W=hello | goal 'a' [empty]. -$ ./$MAKESURE -f tests/27_parameterized_goals_13_priority.sh a +$ ./{{MAKESURE}} -f tests/27_parameterized_goals_13_priority.sh a | goal 'pg@Value' ... | P=Value | in child: P=Value diff --git a/tests/28_revamp_define.tush b/tests/28_revamp_define.tush index f10887c..bbd06d6 100644 --- a/tests/28_revamp_define.tush +++ b/tests/28_revamp_define.tush @@ -1,5 +1,5 @@ -$ ./$MAKESURE -f tests/28_revamp_define_1.sh -l +$ ./{{MAKESURE}} -f tests/28_revamp_define_1.sh -l | Available goals: | g1 | g2 @@ -17,17 +17,17 @@ $ ./$MAKESURE -f tests/28_revamp_define_1.sh -l | pg2@Str | 'pg@the Value' -$ ./$MAKESURE -f tests/28_revamp_define_1.sh g1 +$ ./{{MAKESURE}} -f tests/28_revamp_define_1.sh g1 | goal 'pg@Value' ... | A=Value | goal 'g1' [empty]. -$ ./$MAKESURE -f tests/28_revamp_define_1.sh g2 +$ ./{{MAKESURE}} -f tests/28_revamp_define_1.sh g2 | goal 'pg@Str1' ... | A=Str1 | goal 'g2' [empty]. -$ ./$MAKESURE -f tests/28_revamp_define_1.sh g3 +$ ./{{MAKESURE}} -f tests/28_revamp_define_1.sh g3 | goal 'pg@Str1' ... | A=Str1 | goal 'pg@Value' ... @@ -37,7 +37,7 @@ $ ./$MAKESURE -f tests/28_revamp_define_1.sh g3 | goal 'pg2@Str1' [empty]. | goal 'g3' [empty]. -$ ./$MAKESURE -f tests/28_revamp_define_1.sh g4 +$ ./{{MAKESURE}} -f tests/28_revamp_define_1.sh g4 | goal 'pg@Value' ... | A=Value | goal 'pg@Str' ... @@ -45,7 +45,7 @@ $ ./$MAKESURE -f tests/28_revamp_define_1.sh g4 | goal 'pg2@Value' [empty]. | goal 'g4' [empty]. -$ ./$MAKESURE -f tests/28_revamp_define_1.sh g5 +$ ./{{MAKESURE}} -f tests/28_revamp_define_1.sh g5 | goal 'pg@Value' ... | A=Value | goal 'pg@Str' ... @@ -53,7 +53,7 @@ $ ./$MAKESURE -f tests/28_revamp_define_1.sh g5 | goal 'pg2@Value' [empty]. | goal 'g5' [empty]. -$ ./$MAKESURE -f tests/28_revamp_define_1.sh g6 +$ ./{{MAKESURE}} -f tests/28_revamp_define_1.sh g6 | goal 'pg@Str' ... | A=Str | goal 'pg@Value' ... @@ -61,17 +61,17 @@ $ ./$MAKESURE -f tests/28_revamp_define_1.sh g6 | goal 'pg2@Str' [empty]. | goal 'g6' [empty]. -$ ./$MAKESURE -f tests/28_revamp_define_1.sh g7 +$ ./{{MAKESURE}} -f tests/28_revamp_define_1.sh g7 | goal 'pg@the Value' ... | A=the Value | goal 'g7' [empty]. -$ ./$MAKESURE -f tests/28_revamp_define_1.sh g8 +$ ./{{MAKESURE}} -f tests/28_revamp_define_1.sh g8 | goal 'g8' ... | 1.2.3 email@example.com default\}$" -$ ./$MAKESURE -f tests/28_revamp_define_2_err_quoting.sh -l +$ ./{{MAKESURE}} -f tests/28_revamp_define_2_err_quoting.sh -l @ Wrong quoting: sh: @ tests/28_revamp_define_2_err_quoting.sh:6: @shell "sh" @ Wrong quoting: tracing: @@ -102,13 +102,13 @@ $ ./$MAKESURE -f tests/28_revamp_define_2_err_quoting.sh -l @ tests/28_revamp_define_2_err_quoting.sh:30: @depends_on pg "@args" 'value' ? 1 -$ ./$MAKESURE -f tests/28_revamp_define_3_issue152.sh -l +$ ./{{MAKESURE}} -f tests/28_revamp_define_3_issue152.sh -l | Available goals: | g | pg@aaa | pg@bbb -$ ./$MAKESURE -f tests/28_revamp_define_4_interpolation_including_pg_params.sh g +$ ./{{MAKESURE}} -f tests/28_revamp_define_4_interpolation_including_pg_params.sh g | goal 'pg1@hello world' ... | hello world | goal 'pg@world' [empty]. diff --git a/tests/29_glob_plus_pg.tush b/tests/29_glob_plus_pg.tush index 09a9a37..e91b0e1 100644 --- a/tests/29_glob_plus_pg.tush +++ b/tests/29_glob_plus_pg.tush @@ -1,5 +1,5 @@ -$ ./$MAKESURE -f tests/29_glob_plus_pg_1.sh -l +$ ./{{MAKESURE}} -f tests/29_glob_plus_pg_1.sh -l | Available goals: | g1 | g2 @@ -9,7 +9,7 @@ $ ./$MAKESURE -f tests/29_glob_plus_pg_1.sh -l | g3pg@salut | gpg@salut -$ ./$MAKESURE -f tests/29_glob_plus_pg_1.sh -la +$ ./{{MAKESURE}} -f tests/29_glob_plus_pg_1.sh -la | Available goals: | g1 | g2 @@ -25,7 +25,7 @@ $ ./$MAKESURE -f tests/29_glob_plus_pg_1.sh -la | gpg@glob_test/1.txt@salut | gpg@glob_test/2.txt@salut -$ ./$MAKESURE -f tests/29_glob_plus_pg_1.sh g1 +$ ./{{MAKESURE}} -f tests/29_glob_plus_pg_1.sh g1 | goal 'gpg@glob_test/1.txt@hello' ... | glob_test/1.txt hello | goal 'gpg@glob_test/2.txt@hello' ... @@ -33,7 +33,7 @@ $ ./$MAKESURE -f tests/29_glob_plus_pg_1.sh g1 | goal 'gpg@hello' [empty]. | goal 'g1' [empty]. -$ ./$MAKESURE -f tests/29_glob_plus_pg_1.sh g2 +$ ./{{MAKESURE}} -f tests/29_glob_plus_pg_1.sh g2 | goal 'gpg@glob_test/1.txt@hello' ... | glob_test/1.txt hello | goal 'gpg@glob_test/2.txt@hello' ... @@ -46,7 +46,7 @@ $ ./$MAKESURE -f tests/29_glob_plus_pg_1.sh g2 | goal 'gpg@hi' [empty]. | goal 'g2' [empty]. -$ ./$MAKESURE -f tests/29_glob_plus_pg_1.sh g3 +$ ./{{MAKESURE}} -f tests/29_glob_plus_pg_1.sh g3 | goal 'gpg@glob_test/1.txt@salut' ... | glob_test/1.txt salut | goal 'gpg@glob_test/2.txt@salut' ... @@ -55,7 +55,7 @@ $ ./$MAKESURE -f tests/29_glob_plus_pg_1.sh g3 | goal 'g3pg@salut' [empty]. | goal 'g3' [empty]. -$ ./$MAKESURE -f tests/29_glob_plus_pg_2.sh -l +$ ./{{MAKESURE}} -f tests/29_glob_plus_pg_2.sh -l | Available goals: | g1 | g2 @@ -65,7 +65,7 @@ $ ./$MAKESURE -f tests/29_glob_plus_pg_2.sh -l | g3pg@salut | 'glob_test/*.txt@salut' -$ ./$MAKESURE -f tests/29_glob_plus_pg_2.sh -la +$ ./{{MAKESURE}} -f tests/29_glob_plus_pg_2.sh -la | Available goals: | g1 | g2 @@ -81,7 +81,7 @@ $ ./$MAKESURE -f tests/29_glob_plus_pg_2.sh -la | glob_test/1.txt@salut | glob_test/2.txt@salut -$ ./$MAKESURE -f tests/29_glob_plus_pg_2.sh g1 +$ ./{{MAKESURE}} -f tests/29_glob_plus_pg_2.sh g1 | goal 'glob_test/1.txt@hello' ... | glob_test/1.txt hello | goal 'glob_test/2.txt@hello' ... @@ -89,7 +89,7 @@ $ ./$MAKESURE -f tests/29_glob_plus_pg_2.sh g1 | goal 'glob_test/*.txt@hello' [empty]. | goal 'g1' [empty]. -$ ./$MAKESURE -f tests/29_glob_plus_pg_2.sh g2 +$ ./{{MAKESURE}} -f tests/29_glob_plus_pg_2.sh g2 | goal 'glob_test/1.txt@hello' ... | glob_test/1.txt hello | goal 'glob_test/2.txt@hello' ... @@ -102,7 +102,7 @@ $ ./$MAKESURE -f tests/29_glob_plus_pg_2.sh g2 | goal 'glob_test/*.txt@hi' [empty]. | goal 'g2' [empty]. -$ ./$MAKESURE -f tests/29_glob_plus_pg_2.sh g3 +$ ./{{MAKESURE}} -f tests/29_glob_plus_pg_2.sh g3 | goal 'glob_test/1.txt@salut' ... | glob_test/1.txt salut | goal 'glob_test/2.txt@salut' ... @@ -111,7 +111,7 @@ $ ./$MAKESURE -f tests/29_glob_plus_pg_2.sh g3 | goal 'g3pg@salut' [empty]. | goal 'g3' [empty]. -$ ./$MAKESURE -f tests/29_glob_plus_pg_3.sh -l +$ ./{{MAKESURE}} -f tests/29_glob_plus_pg_3.sh -l | Available goals: | g1 | g2 @@ -121,7 +121,7 @@ $ ./$MAKESURE -f tests/29_glob_plus_pg_3.sh -l | g3pg@salut | glob_test/1.txt@salut -$ ./$MAKESURE -f tests/29_glob_plus_pg_3.sh -la +$ ./{{MAKESURE}} -f tests/29_glob_plus_pg_3.sh -la | Available goals: | g1 | g2 @@ -131,19 +131,19 @@ $ ./$MAKESURE -f tests/29_glob_plus_pg_3.sh -la | g3pg@salut | glob_test/1.txt@salut -$ ./$MAKESURE -f tests/29_glob_plus_pg_3.sh g1 +$ ./{{MAKESURE}} -f tests/29_glob_plus_pg_3.sh g1 | goal 'glob_test/1.txt@hello' ... | glob_test/1.txt hello | goal 'g1' [empty]. -$ ./$MAKESURE -f tests/29_glob_plus_pg_3.sh g2 +$ ./{{MAKESURE}} -f tests/29_glob_plus_pg_3.sh g2 | goal 'glob_test/1.txt@hello' ... | glob_test/1.txt hello | goal 'glob_test/1.txt@hi' ... | glob_test/1.txt hi | goal 'g2' [empty]. -$ ./$MAKESURE -f tests/29_glob_plus_pg_3.sh g3 +$ ./{{MAKESURE}} -f tests/29_glob_plus_pg_3.sh g3 | goal 'glob_test/1.txt@salut' ... | glob_test/1.txt salut | goal 'g3pg@salut' [empty]. diff --git a/tests/2_mydir.tush b/tests/2_mydir.tush index dc03607..650a7ae 100644 --- a/tests/2_mydir.tush +++ b/tests/2_mydir.tush @@ -1,40 +1,40 @@ -$ ./$MAKESURE -f tests/2_mydir.sh mydir_1 +$ ./{{MAKESURE}} -f tests/2_mydir.sh mydir_1 | goal 'mydir_1' ... | mydir -$ ./$MAKESURE -f tests/2_mydir.sh mydir_2 +$ ./{{MAKESURE}} -f tests/2_mydir.sh mydir_2 | goal 'mydir_2' ... | mydir -$ ./$MAKESURE -f tests/dir\ with\ spaces/2_mydir.sh +$ ./{{MAKESURE}} -f tests/dir\ with\ spaces/2_mydir.sh | goal 'default' ... | mydir -$ cd "tests/dir with spaces"; ../../$MAKESURE -f 2_mydir.sh +$ cd "tests/dir with spaces"; ../../{{MAKESURE}} -f 2_mydir.sh | goal 'default' ... | mydir -$ ./$MAKESURE -f tests/2_mydir.sh mydir_in_reached_if_1 +$ ./{{MAKESURE}} -f tests/2_mydir.sh mydir_in_reached_if_1 | goal 'mydir_in_reached_if_1' [already satisfied]. -$ ./$MAKESURE -f tests/2_mydir.sh mydir_in_reached_if_2 +$ ./{{MAKESURE}} -f tests/2_mydir.sh mydir_in_reached_if_2 | goal 'mydir_in_reached_if_2' [already satisfied]. -$ ./$MAKESURE -f tests/2_mydir.sh mydir_in_reached_if_4 +$ ./{{MAKESURE}} -f tests/2_mydir.sh mydir_in_reached_if_4 | goal 'mydir_in_reached_if_4' ... | should show -$ ./$MAKESURE -f tests/2_mydir.sh mydir_in_reached_if_5 +$ ./{{MAKESURE}} -f tests/2_mydir.sh mydir_in_reached_if_5 | goal 'mydir_in_reached_if_5' ... | should show -$ ./$MAKESURE -f tests/2_mydir.sh mydir_in_reached_if_of_dep_1 +$ ./{{MAKESURE}} -f tests/2_mydir.sh mydir_in_reached_if_of_dep_1 | goal 'dep_1' [already satisfied]. | goal 'mydir_in_reached_if_of_dep_1' ... | should show -$ ./$MAKESURE -f tests/2_mydir.sh mydir_in_reached_if_of_dep_2 +$ ./{{MAKESURE}} -f tests/2_mydir.sh mydir_in_reached_if_of_dep_2 | goal 'dep_3' ... | dep_3 | goal 'dep_2' ... diff --git a/tests/30_errors_when_glob.tush b/tests/30_errors_when_glob.tush index 3b61c17..49ecc1c 100644 --- a/tests/30_errors_when_glob.tush +++ b/tests/30_errors_when_glob.tush @@ -1,5 +1,5 @@ -$ ./$MAKESURE -f tests/30_errors_when_glob.sh +$ ./{{MAKESURE}} -f tests/30_errors_when_glob.sh @ Multiple @doc not allowed for a goal: @ tests/30_errors_when_glob.sh:7: @doc 'bbb' @ Multiple @reached_if not allowed for a goal: diff --git a/tests/31_glob_interpolated.tush b/tests/31_glob_interpolated.tush index ae68563..b036396 100644 --- a/tests/31_glob_interpolated.tush +++ b/tests/31_glob_interpolated.tush @@ -1,19 +1,19 @@ -$ ./$MAKESURE -f tests/31_glob_interpolated.sh g1 +$ ./{{MAKESURE}} -f tests/31_glob_interpolated.sh g1 | goal 'g1@glob_test/1.txt' ... | glob_test/1.txt | goal 'g1@glob_test/2.txt' ... | glob_test/2.txt | goal 'g1' [empty]. -$ ./$MAKESURE -f tests/31_glob_interpolated.sh g2 +$ ./{{MAKESURE}} -f tests/31_glob_interpolated.sh g2 | goal 'g2@glob_test/1.txt' ... | glob_test/1.txt | goal 'g2@glob_test/2.txt' ... | glob_test/2.txt | goal 'g2' [empty]. -$ ./$MAKESURE -f tests/31_glob_interpolated.sh g3 +$ ./{{MAKESURE}} -f tests/31_glob_interpolated.sh g3 | goal 'g3@glob_test/1.txt' ... | glob_test/1.txt | goal 'g3@glob_test/2.txt' ... diff --git a/tests/32_calls.tush b/tests/32_calls.tush index f3f756e..718b5fe 100644 --- a/tests/32_calls.tush +++ b/tests/32_calls.tush @@ -1,41 +1,41 @@ === loop detection === -$ ./$MAKESURE -f tests/32_calls_loop.sh a +$ ./{{MAKESURE}} -f tests/32_calls_loop.sh a @ There is a loop in goal dependencies via a -> c ? 1 -$ ./$MAKESURE -f tests/32_calls.sh aa +$ ./{{MAKESURE}} -f tests/32_calls.sh aa | goal 'aa' ... | goal 'a1' ... | A1 | goal 'a2' ... | A2 -$ touch /tmp/x ; ./$MAKESURE -f tests/32_calls.sh x-updated +$ touch /tmp/x ; ./{{MAKESURE}} -f tests/32_calls.sh x-updated | goal 'x-updated' ... | goal 'x-deleted' ... | running x-deleted | goal 'x-created' ... | running x-created -$ touch /tmp/x ; ./$MAKESURE -f tests/32_calls.sh x-updated-1 +$ touch /tmp/x ; ./{{MAKESURE}} -f tests/32_calls.sh x-updated-1 | goal 'x-updated-1' ... | goal 'x-deleted' ... | running x-deleted | goal 'x-created' ... | running x-created -$ ./$MAKESURE -f tests/32_calls.sh a +$ ./{{MAKESURE}} -f tests/32_calls.sh a | goal 'a' ... | goal 'b' ... | b body | a body -$ touch /tmp/x ; ./$MAKESURE -f tests/32_calls.sh x-updated --silent +$ touch /tmp/x ; ./{{MAKESURE}} -f tests/32_calls.sh x-updated --silent | running x-deleted | running x-created -$ touch /tmp/x ; ./$MAKESURE -f tests/32_calls.sh x-updated --timing | sed 's#took .*$#took X#g ; s#total time .*$#total time X#g' +$ touch /tmp/x ; ./{{MAKESURE}} -f tests/32_calls.sh x-updated --timing | sed 's#took .*$#took X#g ; s#total time .*$#total time X#g' | goal 'x-updated' ... | goal 'x-deleted' ... | running x-deleted @@ -46,7 +46,7 @@ $ touch /tmp/x ; ./$MAKESURE -f tests/32_calls.sh x-updated --timing | sed 's#to | goal 'x-updated' took X | total time X -$ touch /tmp/x ; ./$MAKESURE -f tests/32_calls.sh x-updated --tracing 2>&1 | awk -f tests/unify_tracing_output.awk +$ touch /tmp/x ; ./{{MAKESURE}} -f tests/32_calls.sh x-updated --tracing 2>&1 | awk -f tests/unify_tracing_output.awk | goal 'x-updated' ... | goal 'x-deleted' ... | running x-deleted @@ -71,7 +71,7 @@ $ touch /tmp/x ; ./$MAKESURE -f tests/32_calls.sh x-updated --tracing 2>&1 | aw @ + echo 'running x-created' @ + touch /tmp/x -$ ./$MAKESURE -f tests/32_calls.sh gg +$ ./{{MAKESURE}} -f tests/32_calls.sh gg | goal 'gg@glob/file_1.txt' ... | goal 'b' ... | b body @@ -87,7 +87,7 @@ $ ./$MAKESURE -f tests/32_calls.sh gg | goal 'gg' [empty]. === parameterized goals === -$ ./$MAKESURE -f tests/32_calls_pg.sh c +$ ./{{MAKESURE}} -f tests/32_calls_pg.sh c | goal 'c' ... | goal 'pg@a_val@b_val' ... | pg body: a_val b_val @@ -95,18 +95,18 @@ $ ./$MAKESURE -f tests/32_calls_pg.sh c | pg body: a_val b_val === defines === -$ ./$MAKESURE -f tests/32_calls_define.sh b +$ ./{{MAKESURE}} -f tests/32_calls_define.sh b | goal 'b' ... | goal 'a' ... | a: A -$ ./$MAKESURE -f tests/32_calls_define.sh b --define A=AA +$ ./{{MAKESURE}} -f tests/32_calls_define.sh b --define A=AA | goal 'b' ... | goal 'a' ... | a: AA === @calls + @depends_on === -$ ./$MAKESURE -f tests/32_calls.sh ggg +$ ./{{MAKESURE}} -f tests/32_calls.sh ggg | goal 'g2' ... | g2 | goal 'ggg' ... @@ -118,13 +118,13 @@ $ ./$MAKESURE -f tests/32_calls.sh ggg === --resolved === it was decided we don't display any information for the @calls for now -$ ./$MAKESURE -f tests/32_calls.sh ggg --resolved +$ ./{{MAKESURE}} -f tests/32_calls.sh ggg --resolved | Resolved goals to reach for 'ggg': | g2 | ggg === invalid scenarios === -$ ./$MAKESURE -f tests/32_calls_invalid_usage.sh -l +$ ./{{MAKESURE}} -f tests/32_calls_invalid_usage.sh -l @ Only use @calls in @goal: @ tests/32_calls_invalid_usage.sh:2: @calls a @ Only use @calls in @goal: diff --git a/tests/33_issue_183_directives_order.tush b/tests/33_issue_183_directives_order.tush index 7a3606f..022b3f6 100644 --- a/tests/33_issue_183_directives_order.tush +++ b/tests/33_issue_183_directives_order.tush @@ -1,11 +1,11 @@ -$ ./$MAKESURE -f tests/33_issue_183_directives_order_ok.sh b +$ ./{{MAKESURE}} -f tests/33_issue_183_directives_order_ok.sh b | goal 'a' ... | a | goal 'b' ... | b -$ ./$MAKESURE -f tests/33_issue_183_directives_order.sh b +$ ./{{MAKESURE}} -f tests/33_issue_183_directives_order.sh b @ Only use @depends_on in @goal: @ tests/33_issue_183_directives_order.sh:6: @depends_on a # should be disallowed in this position @ Only use @reached_if in @goal: diff --git a/tests/34_glob_except.tush b/tests/34_glob_except.tush index 77f0cb6..b72dcb9 100644 --- a/tests/34_glob_except.tush +++ b/tests/34_glob_except.tush @@ -1,5 +1,5 @@ -$ ./$MAKESURE -f tests/34_glob_except.sh -l +$ ./{{MAKESURE}} -f tests/34_glob_except.sh -l | Available goals: | 'glob/file*.txt' : test goal_glob | test1 @@ -9,7 +9,7 @@ $ ./$MAKESURE -f tests/34_glob_except.sh -l | glob_goal_name3 | empty_glob -$ ./$MAKESURE -f tests/34_glob_except.sh -la +$ ./{{MAKESURE}} -f tests/34_glob_except.sh -la | Available goals: | glob/file_1.txt : test goal_glob | glob/file_3.txt : test goal_glob @@ -29,13 +29,13 @@ $ ./$MAKESURE -f tests/34_glob_except.sh -la | glob_goal_name3 | empty_glob -$ ./$MAKESURE -f tests/34_glob_except.sh -d 'glob/file*.txt' +$ ./{{MAKESURE}} -f tests/34_glob_except.sh -d 'glob/file*.txt' | Resolved goals to reach for 'glob/file*.txt': | glob/file_1.txt | glob/file_3.txt | glob/file_10.txt -$ ./$MAKESURE -f tests/34_glob_except.sh 'glob/file*.txt' +$ ./{{MAKESURE}} -f tests/34_glob_except.sh 'glob/file*.txt' | goal 'glob/file_1.txt' ... | glob/file_1.txt :: 0 :: 3 | content 111 @@ -47,7 +47,7 @@ $ ./$MAKESURE -f tests/34_glob_except.sh 'glob/file*.txt' | content 101010 | goal 'glob/file*.txt' [empty]. -$ ./$MAKESURE -f tests/34_glob_except.sh test1 +$ ./{{MAKESURE}} -f tests/34_glob_except.sh test1 | goal 'glob/file_1.txt' ... | glob/file_1.txt :: 0 :: 3 | content 111 @@ -56,14 +56,14 @@ $ ./$MAKESURE -f tests/34_glob_except.sh test1 | content 333 | goal 'test1' [empty]. -$ ./$MAKESURE -f tests/34_glob_except.sh test2 +$ ./{{MAKESURE}} -f tests/34_glob_except.sh test2 | goal 'glob_goal_name@glob/file_2.txt' ... | glob_goal_name ::: glob/file_2.txt :: 0 :: 3 | goal 'glob_goal_name@glob/file_3.txt' ... | glob_goal_name ::: glob/file_3.txt :: 1 :: 3 | goal 'test2' [empty]. -$ ./$MAKESURE -f tests/34_glob_except.sh glob_goal_name +$ ./{{MAKESURE}} -f tests/34_glob_except.sh glob_goal_name | goal 'glob_goal_name@glob/file_2.txt' ... | glob_goal_name ::: glob/file_2.txt :: 0 :: 3 | goal 'glob_goal_name@glob/file_3.txt' ... @@ -72,19 +72,19 @@ $ ./$MAKESURE -f tests/34_glob_except.sh glob_goal_name | glob_goal_name ::: glob/file_10.txt :: 2 :: 3 | goal 'glob_goal_name' [empty]. -$ ./$MAKESURE -f tests/34_glob_except.sh glob_goal_name2 +$ ./{{MAKESURE}} -f tests/34_glob_except.sh glob_goal_name2 | goal 'glob_goal_name2@glob/file_3.txt' ... | glob_goal_name ::: glob/file_3.txt :: 0 :: 2 | goal 'glob_goal_name2@glob/file_10.txt' ... | glob_goal_name ::: glob/file_10.txt :: 1 :: 2 | goal 'glob_goal_name2' [empty]. -$ ./$MAKESURE -f tests/34_glob_except.sh glob_goal_name3 +$ ./{{MAKESURE}} -f tests/34_glob_except.sh glob_goal_name3 | goal 'glob_goal_name3@glob/file_3.txt' ... | glob_goal_name ::: glob/file_3.txt :: 0 :: 2 | goal 'glob_goal_name3@glob/file_10.txt' ... | glob_goal_name ::: glob/file_10.txt :: 1 :: 2 | goal 'glob_goal_name3' [empty]. -$ ./$MAKESURE -f tests/34_glob_except.sh empty_glob +$ ./{{MAKESURE}} -f tests/34_glob_except.sh empty_glob | goal 'empty_glob' [empty]. diff --git a/tests/35_glob_depends_on.tush b/tests/35_glob_depends_on.tush index 87dc560..9e50f34 100644 --- a/tests/35_glob_depends_on.tush +++ b/tests/35_glob_depends_on.tush @@ -1,5 +1,5 @@ -$ ./$MAKESURE -f tests/35_glob_depends_on.sh b +$ ./{{MAKESURE}} -f tests/35_glob_depends_on.sh b | goal 'a@glob_test/1.txt' ... | a glob_test/1.txt | goal 'b@glob_test/1.txt' ... @@ -10,7 +10,7 @@ $ ./$MAKESURE -f tests/35_glob_depends_on.sh b | b glob_test/2.txt | goal 'b' [empty]. -$ ./$MAKESURE -f tests/35_glob_depends_on.sh b2 +$ ./{{MAKESURE}} -f tests/35_glob_depends_on.sh b2 | goal 'b2@glob_test/1.txt' ... | goal 'a@glob_test/1.txt' ... | a glob_test/1.txt @@ -25,7 +25,7 @@ $ ./$MAKESURE -f tests/35_glob_depends_on.sh b2 | b2 glob_test/2.txt | goal 'b2' [empty]. -$ ./$MAKESURE -f tests/35_glob_depends_on.sh b3 +$ ./{{MAKESURE}} -f tests/35_glob_depends_on.sh b3 | goal 'glob_test/1.txt' ... | noname glob_test/1.txt | goal 'b3@glob_test/1.txt' ... @@ -36,7 +36,7 @@ $ ./$MAKESURE -f tests/35_glob_depends_on.sh b3 | b3 glob_test/2.txt | goal 'b3' [empty]. -$ ./$MAKESURE -f tests/35_glob_depends_on.sh c +$ ./{{MAKESURE}} -f tests/35_glob_depends_on.sh c | goal 'a@glob_test/1.txt' ... | a glob_test/1.txt | goal 'b@glob_test/1.txt' ... @@ -51,7 +51,7 @@ $ ./$MAKESURE -f tests/35_glob_depends_on.sh c | c glob_test/2.txt | goal 'c' [empty]. -$ ./$MAKESURE -f tests/35_glob_depends_on.sh d +$ ./{{MAKESURE}} -f tests/35_glob_depends_on.sh d | goal 'a@glob_test/1.txt' ... | a glob_test/1.txt | goal 'a2@glob_test/1.txt' ... @@ -66,7 +66,7 @@ $ ./$MAKESURE -f tests/35_glob_depends_on.sh d | d glob_test/2.txt | goal 'd' [empty]. -$ ./$MAKESURE -f tests/35_glob_depends_on.sh e +$ ./{{MAKESURE}} -f tests/35_glob_depends_on.sh e | goal 'a@glob_test/1.txt' ... | a glob_test/1.txt | goal 'b@glob_test/1.txt' ... @@ -81,7 +81,7 @@ $ ./$MAKESURE -f tests/35_glob_depends_on.sh e | e glob_test/2.txt | goal 'e' [empty]. -$ ./$MAKESURE -f tests/35_glob_depends_on_err.sh b +$ ./{{MAKESURE}} -f tests/35_glob_depends_on_err.sh b @ Only use @item inside @goal @glob: @ tests/35_glob_depends_on_err.sh:10: @depends_on @item a @ Goal 'b@glob_test/2.txt' has unknown dependency 'a@glob_test/2.txt': diff --git a/tests/3_loop.tush b/tests/3_loop.tush index c01eba4..7c4c05e 100644 --- a/tests/3_loop.tush +++ b/tests/3_loop.tush @@ -1,4 +1,4 @@ -$ ./$MAKESURE -f tests/3_loop.sh a +$ ./{{MAKESURE}} -f tests/3_loop.sh a @ There is a loop in goal dependencies via a -> c ? 1 diff --git a/tests/4_trace.tush b/tests/4_trace.tush index 6f7d8c7..6b7210b 100644 --- a/tests/4_trace.tush +++ b/tests/4_trace.tush @@ -1,12 +1,12 @@ -$ ./$MAKESURE -f tests/4_trace.sh +$ ./{{MAKESURE}} -f tests/4_trace.sh | goal 'goal2' [already satisfied]. | goal 'goal1' ... | goal1 | goal 'default' ... | A=aaa -$ ./$MAKESURE -f tests/4_trace.sh -x 2>&1 | awk -f tests/unify_tracing_output.awk +$ ./{{MAKESURE}} -f tests/4_trace.sh -x 2>&1 | awk -f tests/unify_tracing_output.awk | goal 'goal2' [already satisfied]. | goal 'goal1' ... | goal1 @@ -33,7 +33,7 @@ $ ./$MAKESURE -f tests/4_trace.sh -x 2>&1 | awk -f tests/unify_tracing_o @ + export A @ + echo A=aaa -$ ./$MAKESURE -f tests/4_trace.sh --tracing 2>&1 | awk -f tests/unify_tracing_output.awk +$ ./{{MAKESURE}} -f tests/4_trace.sh --tracing 2>&1 | awk -f tests/unify_tracing_output.awk | goal 'goal2' [already satisfied]. | goal 'goal1' ... | goal1 @@ -61,14 +61,14 @@ $ ./$MAKESURE -f tests/4_trace.sh --tracing 2>&1 | awk -f tests/unify_tracing_o @ + echo A=aaa -$ ./$MAKESURE -f tests/4_trace_shell_sh.sh +$ ./{{MAKESURE}} -f tests/4_trace_shell_sh.sh | goal 'goal2' [already satisfied]. | goal 'goal1' ... | goal1 | goal 'default' ... | A=aaa -$ ./$MAKESURE -f tests/4_trace_shell_sh.sh -x 2>&1 | awk -f tests/unify_tracing_output.awk +$ ./{{MAKESURE}} -f tests/4_trace_shell_sh.sh -x 2>&1 | awk -f tests/unify_tracing_output.awk | goal 'goal2' [already satisfied]. | goal 'goal1' ... | goal1 @@ -95,7 +95,7 @@ $ ./$MAKESURE -f tests/4_trace_shell_sh.sh -x 2>&1 | awk -f tests/unify_ @ + export A @ + echo A=aaa -$ ./$MAKESURE -f tests/4_trace_shell_sh.sh --tracing 2>&1 | awk -f tests/unify_tracing_output.awk +$ ./{{MAKESURE}} -f tests/4_trace_shell_sh.sh --tracing 2>&1 | awk -f tests/unify_tracing_output.awk | goal 'goal2' [already satisfied]. | goal 'goal1' ... | goal1 diff --git a/tests/5_shell.tush b/tests/5_shell.tush index 4882af2..c7649f6 100644 --- a/tests/5_shell.tush +++ b/tests/5_shell.tush @@ -1,23 +1,23 @@ -$ ./$MAKESURE -f tests/5_shell_bash.sh +$ ./{{MAKESURE}} -f tests/5_shell_bash.sh | goal 'default' ... | bash -$ ./$MAKESURE -f tests/5_shell_sh.sh +$ ./{{MAKESURE}} -f tests/5_shell_sh.sh | goal 'default' ... | sh -$ ./$MAKESURE -f tests/5_shell_sh.sh a +$ ./{{MAKESURE}} -f tests/5_shell_sh.sh a | goal 'b' [already satisfied]. | goal 'a' ... | should show -$ ./$MAKESURE -f tests/5_shell_not_supported.sh +$ ./{{MAKESURE}} -f tests/5_shell_not_supported.sh @ Shell 'not_supported' is not supported: @ tests/5_shell_not_supported.sh:1: @shell not_supported ? 1 -$ ./$MAKESURE -f tests/5_shell_in_goal.sh +$ ./{{MAKESURE}} -f tests/5_shell_in_goal.sh @ Only use @shell in prelude: @ tests/5_shell_in_goal.sh:3: @shell sh ? 1 diff --git a/tests/6_reached_if.tush b/tests/6_reached_if.tush index 3cf440b..dbeabec 100644 --- a/tests/6_reached_if.tush +++ b/tests/6_reached_if.tush @@ -1,33 +1,33 @@ -$ ./$MAKESURE -f tests/6_reached_if.sh +$ ./{{MAKESURE}} -f tests/6_reached_if.sh | goal 'bbb' [already satisfied]. | goal 'aaa' ... | aaa | goal 'default' [empty]. -$ ./$MAKESURE -f tests/6_reached_if.sh -d +$ ./{{MAKESURE}} -f tests/6_reached_if.sh -d | Resolved goals to reach for 'default': | aaa -$ ./$MAKESURE -f tests/6_reached_if.sh --resolved bbb +$ ./{{MAKESURE}} -f tests/6_reached_if.sh --resolved bbb | Resolved goals to reach for 'bbb': -$ ./$MAKESURE -f tests/6_reached_if_issue_113.sh g1 +$ ./{{MAKESURE}} -f tests/6_reached_if_issue_113.sh g1 | goal 'g1' [already satisfied]. -$ ./$MAKESURE -f tests/6_reached_if_issue_113.sh g2 +$ ./{{MAKESURE}} -f tests/6_reached_if_issue_113.sh g2 | goal 'g2' ... | must show -$ ./$MAKESURE -f tests/6_reached_if_issue_142.sh g +$ ./{{MAKESURE}} -f tests/6_reached_if_issue_142.sh g | a b | goal 'g' [already satisfied]. -$ ./$MAKESURE -f tests/6_reached_if_issue_142.sh g1 +$ ./{{MAKESURE}} -f tests/6_reached_if_issue_142.sh g1 | a b | goal 'g1' [already satisfied]. -$ ./$MAKESURE -f tests/6_reached_if_issue_142.sh g2 +$ ./{{MAKESURE}} -f tests/6_reached_if_issue_142.sh g2 | a b | goal 'g2' [already satisfied]. diff --git a/tests/7_options.tush b/tests/7_options.tush index 06a6a8c..a8ff76d 100644 --- a/tests/7_options.tush +++ b/tests/7_options.tush @@ -1,20 +1,20 @@ -$ ./$MAKESURE -f tests/7_options_silent.sh +$ ./{{MAKESURE}} -f tests/7_options_silent.sh | ccc | bbb | aaa -$ ./$MAKESURE -f tests/7_options_invalid.sh +$ ./{{MAKESURE}} -f tests/7_options_invalid.sh @ Option 'invalid' is not supported: @ tests/7_options_invalid.sh:2: @options invalid ? 1 -$ ./$MAKESURE -f tests/7_options_in_goal.sh +$ ./{{MAKESURE}} -f tests/7_options_in_goal.sh @ Only use @options in prelude: @ tests/7_options_in_goal.sh:3: @options tracing ? 1 -$ ./$MAKESURE -f tests/7_options_tracing.sh 2>&1 | awk -f tests/unify_tracing_output.awk +$ ./{{MAKESURE}} -f tests/7_options_tracing.sh 2>&1 | awk -f tests/unify_tracing_output.awk | goal 'default' ... | test @ + : default diff --git a/tests/8_timing.tush b/tests/8_timing.tush index 09550de..dd6c406 100644 --- a/tests/8_timing.tush +++ b/tests/8_timing.tush @@ -1,11 +1,11 @@ -$ ./$MAKESURE -f tests/8_options_timing.sh | sed 's#took .*$#took X#g ; s#total time .*$#total time X#g' +$ ./{{MAKESURE}} -f tests/8_options_timing.sh | sed 's#took .*$#took X#g ; s#total time .*$#total time X#g' | goal 'default' ... | test | goal 'default' took X | total time X -$ ./$MAKESURE -f tests/8_options_timing.sh empty_goal | sed 's#took .*$#took X#g ; s#total time .*$#total time X#g' +$ ./{{MAKESURE}} -f tests/8_options_timing.sh empty_goal | sed 's#took .*$#took X#g ; s#total time .*$#total time X#g' | goal 'reached_goal' [already satisfied]. | goal 'not_reached_goal_1' ... | should show 1 @@ -16,14 +16,14 @@ $ ./$MAKESURE -f tests/8_options_timing.sh empty_goal | sed 's#took .*$#took X#g | goal 'empty_goal' [empty]. | total time X -$ ./$MAKESURE -f tests/8_options_timing_silent.sh +$ ./{{MAKESURE}} -f tests/8_options_timing_silent.sh | test -$ ./$MAKESURE -t -f tests/8_timing.sh | sed 's#took .*$#took X#g ; s#total time .*$#total time X#g' +$ ./{{MAKESURE}} -t -f tests/8_timing.sh | sed 's#took .*$#took X#g ; s#total time .*$#total time X#g' | goal 'default' ... | test | goal 'default' took X | total time X -$ ./$MAKESURE -t -s -f tests/8_timing.sh +$ ./{{MAKESURE}} -t -s -f tests/8_timing.sh | test diff --git a/tests/9_prelude.tush b/tests/9_prelude.tush index e59660b..d614454 100644 --- a/tests/9_prelude.tush +++ b/tests/9_prelude.tush @@ -1,5 +1,5 @@ -$ ./$MAKESURE -f tests/9_prelude.sh a +$ ./{{MAKESURE}} -f tests/9_prelude.sh a | goal 'c' [already satisfied]. | goal 'd' ... | d @@ -8,17 +8,17 @@ $ ./$MAKESURE -f tests/9_prelude.sh a | goal 'a' ... | a -$ ./$MAKESURE -f tests/9_prelude_doc.sh +$ ./{{MAKESURE}} -f tests/9_prelude_doc.sh @ Only use @doc in @goal: @ tests/9_prelude_doc.sh:2: @doc Doc in prelude ? 1 -$ ./$MAKESURE -f tests/9_prelude_depends_on.sh +$ ./{{MAKESURE}} -f tests/9_prelude_depends_on.sh @ Only use @depends_on in @goal: @ tests/9_prelude_depends_on.sh:2: @depends_on g1 ? 1 -$ ./$MAKESURE -f tests/9_prelude_reached_if.sh +$ ./{{MAKESURE}} -f tests/9_prelude_reached_if.sh @ Only use @reached_if in @goal: @ tests/9_prelude_reached_if.sh:2: @reached_if aaa ? 1