diff options
-rw-r--r-- | build2/test/rule.cxx | 4 | ||||
-rw-r--r-- | build2/test/target.cxx | 8 | ||||
-rw-r--r-- | doc/manual.cli | 2 | ||||
-rw-r--r-- | doc/testscript.cli | 71 | ||||
-rw-r--r-- | tests/bash/testscript | 2 | ||||
-rw-r--r-- | tests/build/root.build | 2 | ||||
-rw-r--r-- | tests/buildfile | 2 | ||||
-rw-r--r-- | tests/cc/libu/testscript | 2 | ||||
-rw-r--r-- | tests/cc/modules/testscript | 2 | ||||
-rw-r--r-- | tests/cc/preprocessed/testscript | 2 | ||||
-rw-r--r-- | tests/common.testscript (renamed from tests/common.test) | 2 | ||||
-rw-r--r-- | tests/directive/assert.testscript (renamed from tests/directive/assert.test) | 4 | ||||
-rw-r--r-- | tests/directive/buildfile | 2 | ||||
-rw-r--r-- | tests/directive/run.testscript (renamed from tests/directive/run.test) | 4 | ||||
-rw-r--r-- | tests/eval/buildfile | 2 | ||||
-rw-r--r-- | tests/eval/comma.testscript (renamed from tests/eval/comma.test) | 4 | ||||
-rw-r--r-- | tests/eval/comp.testscript (renamed from tests/eval/comp.test) | 4 | ||||
-rw-r--r-- | tests/eval/or-and.testscript (renamed from tests/eval/or-and.test) | 4 | ||||
-rw-r--r-- | tests/eval/qual.testscript (renamed from tests/eval/qual.test) | 4 | ||||
-rw-r--r-- | tests/eval/ternary.testscript (renamed from tests/eval/ternary.test) | 4 | ||||
-rw-r--r-- | tests/eval/value.testscript (renamed from tests/eval/value.test) | 4 | ||||
-rw-r--r-- | tests/expansion/buildfile | 2 | ||||
-rw-r--r-- | tests/expansion/concat.testscript (renamed from tests/expansion/concat.test) | 4 | ||||
-rw-r--r-- | tests/expansion/type.testscript (renamed from tests/expansion/type.test) | 4 | ||||
-rw-r--r-- | tests/function/builtin/testscript | 2 | ||||
-rw-r--r-- | tests/function/filesystem/testscript | 2 | ||||
-rw-r--r-- | tests/function/install/testscript | 2 | ||||
-rw-r--r-- | tests/function/path/testscript | 2 | ||||
-rw-r--r-- | tests/function/process/testscript | 2 | ||||
-rw-r--r-- | tests/function/regex/testscript | 2 | ||||
-rw-r--r-- | tests/hooks/testscript | 2 | ||||
-rw-r--r-- | tests/in/testscript | 2 | ||||
-rw-r--r-- | tests/loop/buildfile | 2 | ||||
-rw-r--r-- | tests/loop/for.testscript (renamed from tests/loop/for.test) | 4 | ||||
-rw-r--r-- | tests/name/buildfile | 2 | ||||
-rw-r--r-- | tests/name/cross.testscript (renamed from tests/name/cross.test) | 4 | ||||
-rw-r--r-- | tests/name/extension.testscript (renamed from tests/name/extension.test) | 12 | ||||
-rw-r--r-- | tests/name/pattern.testscript (renamed from tests/name/pattern.test) | 4 | ||||
-rw-r--r-- | tests/search/dir/testscript | 2 | ||||
-rw-r--r-- | tests/test/buildfile | 2 | ||||
-rw-r--r-- | tests/test/common.testscript (renamed from tests/test/common.test) | 2 | ||||
-rw-r--r-- | tests/test/config-test/testscript | 6 | ||||
-rw-r--r-- | tests/test/script/buildfile | 2 | ||||
-rw-r--r-- | tests/test/script/builtin/buildfile | 2 | ||||
-rw-r--r-- | tests/test/script/builtin/cat.testscript (renamed from tests/test/script/builtin/cat.test) | 4 | ||||
-rw-r--r-- | tests/test/script/builtin/cp.testscript (renamed from tests/test/script/builtin/cp.test) | 4 | ||||
-rw-r--r-- | tests/test/script/builtin/echo.testscript (renamed from tests/test/script/builtin/echo.test) | 4 | ||||
-rw-r--r-- | tests/test/script/builtin/ln.testscript (renamed from tests/test/script/builtin/ln.test) | 4 | ||||
-rw-r--r-- | tests/test/script/builtin/mkdir.testscript (renamed from tests/test/script/builtin/mkdir.test) | 4 | ||||
-rw-r--r-- | tests/test/script/builtin/mv.testscript (renamed from tests/test/script/builtin/mv.test) | 4 | ||||
-rw-r--r-- | tests/test/script/builtin/rm.testscript (renamed from tests/test/script/builtin/rm.test) | 4 | ||||
-rw-r--r-- | tests/test/script/builtin/rmdir.testscript (renamed from tests/test/script/builtin/rmdir.test) | 4 | ||||
-rw-r--r-- | tests/test/script/builtin/sed.testscript (renamed from tests/test/script/builtin/sed.test) | 4 | ||||
-rw-r--r-- | tests/test/script/builtin/test.testscript (renamed from tests/test/script/builtin/test.test) | 4 | ||||
-rw-r--r-- | tests/test/script/builtin/touch.testscript (renamed from tests/test/script/builtin/touch.test) | 4 | ||||
-rw-r--r-- | tests/test/script/common.testscript (renamed from tests/test/script/common.test) | 7 | ||||
-rw-r--r-- | tests/test/script/generated/testscript | 4 | ||||
-rw-r--r-- | tests/test/script/integration/testscript | 28 | ||||
-rw-r--r-- | tests/test/script/runner/buildfile | 4 | ||||
-rw-r--r-- | tests/test/script/runner/cleanup.testscript (renamed from tests/test/script/runner/cleanup.test) | 4 | ||||
-rw-r--r-- | tests/test/script/runner/exit.testscript (renamed from tests/test/script/runner/exit.test) | 6 | ||||
-rw-r--r-- | tests/test/script/runner/expr.testscript (renamed from tests/test/script/runner/expr.test) | 4 | ||||
-rw-r--r-- | tests/test/script/runner/if.testscript (renamed from tests/test/script/runner/if.test) | 4 | ||||
-rw-r--r-- | tests/test/script/runner/output.testscript (renamed from tests/test/script/runner/output.test) | 4 | ||||
-rw-r--r-- | tests/test/script/runner/pipe.testscript (renamed from tests/test/script/runner/pipe.test) | 4 | ||||
-rw-r--r-- | tests/test/script/runner/redirect.testscript (renamed from tests/test/script/runner/redirect.test) | 10 | ||||
-rw-r--r-- | tests/test/script/runner/regex.testscript (renamed from tests/test/script/runner/regex.test) | 6 | ||||
-rw-r--r-- | tests/test/script/runner/set.testscript (renamed from tests/test/script/runner/set.test) | 4 | ||||
-rw-r--r-- | tests/test/script/runner/status.testscript (renamed from tests/test/script/runner/status.test) | 4 | ||||
-rw-r--r-- | tests/test/simple/generated/testscript | 2 | ||||
-rw-r--r-- | tests/value/buildfile | 2 | ||||
-rw-r--r-- | tests/value/concat.testscript (renamed from tests/value/concat.test) | 4 | ||||
-rw-r--r-- | tests/value/reverse.testscript (renamed from tests/value/reverse.test) | 4 | ||||
-rw-r--r-- | tests/variable/override/testscript | 2 | ||||
-rw-r--r-- | tests/variable/prerequisite-specific/testscript | 2 | ||||
-rw-r--r-- | tests/variable/scope-specific/testscript | 2 | ||||
-rw-r--r-- | tests/variable/target-specific/testscript | 2 | ||||
-rw-r--r-- | unit-tests/cc/lexer/buildfile | 2 | ||||
-rw-r--r-- | unit-tests/cc/lexer/char-literal.testscript (renamed from unit-tests/cc/lexer/char-literal.test) | 2 | ||||
-rw-r--r-- | unit-tests/cc/lexer/comment.testscript (renamed from unit-tests/cc/lexer/comment.test) | 2 | ||||
-rw-r--r-- | unit-tests/cc/lexer/line.testscript (renamed from unit-tests/cc/lexer/line.test) | 2 | ||||
-rw-r--r-- | unit-tests/cc/lexer/number.testscript (renamed from unit-tests/cc/lexer/number.test) | 2 | ||||
-rw-r--r-- | unit-tests/cc/lexer/preprocessor.testscript (renamed from unit-tests/cc/lexer/preprocessor.test) | 2 | ||||
-rw-r--r-- | unit-tests/cc/lexer/raw-string-literal.testscript (renamed from unit-tests/cc/lexer/raw-string-literal.test) | 2 | ||||
-rw-r--r-- | unit-tests/cc/lexer/string-literal.testscript (renamed from unit-tests/cc/lexer/string-literal.test) | 2 | ||||
-rw-r--r-- | unit-tests/cc/parser/buildfile | 2 | ||||
-rw-r--r-- | unit-tests/cc/parser/module.testscript (renamed from unit-tests/cc/parser/module.test) | 2 | ||||
-rw-r--r-- | unit-tests/function/buildfile | 2 | ||||
-rw-r--r-- | unit-tests/function/call.testscript (renamed from unit-tests/function/call.test) | 2 | ||||
-rw-r--r-- | unit-tests/function/syntax.testscript (renamed from unit-tests/function/syntax.test) | 2 | ||||
-rw-r--r-- | unit-tests/lexer/buildfile | 2 | ||||
-rw-r--r-- | unit-tests/lexer/buildspec.testscript (renamed from unit-tests/lexer/buildspec.test) | 2 | ||||
-rw-r--r-- | unit-tests/lexer/comment.testscript (renamed from unit-tests/lexer/comment.test) | 2 | ||||
-rw-r--r-- | unit-tests/lexer/eval.testscript (renamed from unit-tests/lexer/eval.test) | 2 | ||||
-rw-r--r-- | unit-tests/lexer/quoting.testscript (renamed from unit-tests/lexer/quoting.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/lexer/buildfile | 2 | ||||
-rw-r--r-- | unit-tests/test/script/lexer/command-expansion.testscript (renamed from unit-tests/test/script/lexer/command-expansion.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/lexer/command-line.testscript (renamed from unit-tests/test/script/lexer/command-line.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/lexer/description-line.testscript (renamed from unit-tests/test/script/lexer/description-line.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/lexer/first-token.testscript (renamed from unit-tests/test/script/lexer/first-token.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/lexer/second-token.testscript (renamed from unit-tests/test/script/lexer/second-token.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/lexer/variable-line.testscript (renamed from unit-tests/test/script/lexer/variable-line.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/lexer/variable.testscript (renamed from unit-tests/test/script/lexer/variable.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/parser/buildfile | 2 | ||||
-rw-r--r-- | unit-tests/test/script/parser/cleanup.testscript (renamed from unit-tests/test/script/parser/cleanup.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/parser/command-if.testscript (renamed from unit-tests/test/script/parser/command-if.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/parser/command-re-parse.testscript (renamed from unit-tests/test/script/parser/command-re-parse.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/parser/description.testscript (renamed from unit-tests/test/script/parser/description.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/parser/directive.testscript (renamed from unit-tests/test/script/parser/directive.test) | 28 | ||||
-rw-r--r-- | unit-tests/test/script/parser/exit.testscript (renamed from unit-tests/test/script/parser/exit.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/parser/expansion.testscript (renamed from unit-tests/test/script/parser/expansion.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/parser/here-document.testscript (renamed from unit-tests/test/script/parser/here-document.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/parser/here-string.testscript (renamed from unit-tests/test/script/parser/here-string.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/parser/include.testscript (renamed from unit-tests/test/script/parser/include.test) | 40 | ||||
-rw-r--r-- | unit-tests/test/script/parser/pipe-expr.testscript (renamed from unit-tests/test/script/parser/pipe-expr.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/parser/pre-parse.testscript (renamed from unit-tests/test/script/parser/pre-parse.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/parser/redirect.testscript (renamed from unit-tests/test/script/parser/redirect.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/parser/regex.testscript (renamed from unit-tests/test/script/parser/regex.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/parser/scope-if.testscript (renamed from unit-tests/test/script/parser/scope-if.test) | 2 | ||||
-rw-r--r-- | unit-tests/test/script/parser/scope.testscript (renamed from unit-tests/test/script/parser/scope.test) | 8 | ||||
-rw-r--r-- | unit-tests/test/script/parser/setup-teardown.testscript (renamed from unit-tests/test/script/parser/setup-teardown.test) | 2 |
121 files changed, 261 insertions, 259 deletions
diff --git a/build2/test/rule.cxx b/build2/test/rule.cxx index 282540ca..64cd56c1 100644 --- a/build2/test/rule.cxx +++ b/build2/test/rule.cxx @@ -113,8 +113,8 @@ namespace build2 // it may not be a testable target at all). So as the first step // determine which case this is. // - // If we have any prerequisites of the test{} type, then this is the - // testscript case. + // If we have any prerequisites of the testscript{} type, then this is + // the testscript case. // // If we can, go inside see-through groups. Normally groups won't be // resolvable for this action but then normally they won't contain any diff --git a/build2/test/target.cxx b/build2/test/target.cxx index 25afd0d3..a6adde94 100644 --- a/build2/test/target.cxx +++ b/build2/test/target.cxx @@ -15,9 +15,9 @@ namespace build2 testscript_target_extension (const target_key& tk) { // If the name is special 'testscript', then there is no extension, - // otherwise it is .test. + // otherwise it is .testscript. // - return *tk.name == "testscript" ? "" : "test"; + return *tk.name == "testscript" ? "" : "testscript"; } static bool @@ -39,7 +39,7 @@ namespace build2 if (!e && v != "testscript") { - e = "test"; + e = "testscript"; return true; } } @@ -49,7 +49,7 @@ namespace build2 const target_type testscript::static_type { - "test", + "testscript", &file::static_type, &target_factory<testscript>, &testscript_target_extension, diff --git a/doc/manual.cli b/doc/manual.cli index 4a6f8540..00a6eb50 100644 --- a/doc/manual.cli +++ b/doc/manual.cli @@ -1742,7 +1742,7 @@ expect to see when running the tests: b test c++ hello/cxx{hello} ld hello/exe{hello} -test hello/test{testscript} hello/exe{hello} +test hello/testscript{testscript} hello/exe{hello} hello/testscript:7:1: error: hello/hello exit code 0 == 0 info: stdout: hello/test-hello/missing-name/stdout \ diff --git a/doc/testscript.cli b/doc/testscript.cli index deeba899..921a0f1d 100644 --- a/doc/testscript.cli +++ b/doc/testscript.cli @@ -104,7 +104,7 @@ testscript file tests a specific target we simply list it as a target's prerequisite, for example: \ -exe{hello}: cxx{hello} test{testscript} +exe{hello}: cxx{hello} testscript \ Let's assume our \c{hello} program expects us to pass the name to greet as a @@ -482,9 +482,9 @@ platform test to \c{buildfile}: \ # buildfile -exe{hello}: cxx{hello} test{testscript} +exe{hello}: cxx{hello} testscript -test{*}: windows = ($cxx.target.class == windows) +testscript{*}: windows = ($cxx.target.class == windows) \ \ @@ -612,13 +612,14 @@ prerequisite that describes how to test the target similar to how, for example, the \c{INSTALL} file describes how to install it. For example: \ -exe{hello}: test{testscript} doc{INSTALL README} +exe{hello}: testscript doc{INSTALL README} \ By convention, the testscript file should be called either \c{testscript} if -you only have one or have the \c{.test} extension, for example, -\c{basics.test}. The \c{test} module registers the \c{test{\}} target type to -be used for testscript files. +you only have one or have the \c{.testscript} extension, for example, +\c{basics.testscript}. The \c{test} module registers the \c{testscript{\}} +target type to be used for testscript files. We don't have to use explicit +target type for the \c{testscript} file. A testscript prerequisite can be specified for any target. For example, if our directory contains a bunch of shell scripts that we want to test together, @@ -626,22 +627,22 @@ then it makes sense to specify the testscript prerequisite for the directory target: \ -./: test{basics} +./: testscript{basics} \ During variable lookup if a variable is not found in one of the testscript scopes (see \l{#model Model and Execution}), then the search continues in the \c{buildfile} starting with the target-specific variables of the target being tested (e.g., \c{exe{hello\}}; called \i{test target}), then target-specific -variables of the testscript target (e.g., \c{test{basics\}}; called \i{script -target}), and then continuing with the scopes starting with the one containing -the script target. As a result, a testscript can \"see\" all the existing -buildfile variables plus we can use target-specific variables to pass +variables of the testscript target (e.g., \c{testscript{basics\}}; called +\i{script target}), and then continuing with the scopes starting with the one +containing the script target. As a result, a testscript can \"see\" all the +existing buildfile variables plus we can use target-specific variables to pass additional, test-specific, information to testscrips. As an example, consider this testscript and buildfile pair: \ -# basics.test +# basics.testscript if ($cxx.target.class == windows) test.arguments += $foo @@ -655,19 +656,19 @@ end \ # buildfile -exe{hello}: test{basics} +exe{hello}: testscript{basics} # All testscripts in this scope. # -test{*}: windows = ($cxx.target.class == windows) +testscript{*}: windows = ($cxx.target.class == windows) # All testscripts for target exe{hello}. # exe{hello}: bar = BAR -# Only basics.test. +# Only basics.testscript. # -test{basics}@./: foo = FOO +testscript{basics}@./: foo = FOO \ Additionally, by convention, a number of pre-defined \c{test.*} variables are @@ -678,7 +679,7 @@ variable is automatically set to the target path being tested. For example, given this \c{buildfile}: \ -exe{hello}: test{testscript} +exe{hello}: testscript \ The value of \c{test} inside the testscript will be the absolute path to the @@ -704,7 +705,7 @@ This is how we can implement \c{tests/buildfile} for this setup: \ hello = ../hello/exe{hello} -./: $hello test{testscript} +./: $hello testscript ./: test = $hello include ../hello/ @@ -762,8 +763,8 @@ directory, then the subdirectory is called \c{test}. Otherwise, it is the name of the target prefixed with\c{test-}. For example: \ -./: test{foo} # $out_base/test/ -exe{hello}: test{bar} # $out_base/test-hello/ +./: testscript{foo} # $out_base/test/ +exe{hello}: testscript{bar} # $out_base/test-hello/ \ @@ -787,8 +788,8 @@ A scope (both group and test) has an \i{id}. If not specified explicitly (as part of the description), it is derived automatically from the group/test location in the testscript file (see \l{#syntax-description Description} for details). The id of the implicit outermost scope is the script file name -without the \c{.test} extension, except if the file name is \c{testscript}, -in which case the id is empty. +without the \c{.testscript} extension, except if the file name is +\c{testscript}, in which case the id is empty. Based on the ids each nested group and test has an \i{id path} that uniquely identifies it. It starts with the id of the implied outermost group (unless @@ -799,7 +800,7 @@ temporary directory where the test is executed (as described below). Inside a scope its id path is available via the special \c{$@} variable (read-only). As an example, consider the following testscript file which we assume is -called \c{basics.test}: +called \c{basics.testscript}: \ test0: test0 @@ -861,9 +862,9 @@ is not empty, then the test is considered to have failed (unexpected output). Inside a scope its working directory is available via the special \c{$~} variable (read-only). -As an example, consider the following version of \c{basics.test}. We also -assume that its test target is a directory (so the target test directory is -\c{$out_base/test/}). +As an example, consider the following version of \c{basics.testscript}. We +also assume that its test target is a directory (so the target test directory +is \c{$out_base/test/}). \ : group @@ -960,7 +961,7 @@ the teardown commands are executed sequentially and in the order specified. Again, if any of them fail, the group execution is terminated and the group is considered to have failed. -As an example, consider the following version of \c{basics.test}: +As an example, consider the following version of \c{basics.testscript}: \ test0 @@ -1016,7 +1017,7 @@ for this example: A testscript would normally contain multiple tests and sometimes it is desirable to only execute a specific test or a group of tests. For example, you may be debugging a failing test and would like to re-run it. As an -example, consider the following testscript file called \c{basics.test}: +example, consider the following testscript file called \c{basics.testscript}: \ $* foo : foo @@ -1037,10 +1038,10 @@ basics/fox/baz \ To only run individual tests, test groups, or testscript files we can specify -their id paths in the \c{config.test} variable, for example: +their id paths in the \c{config.testscript} variable, for example: \ -$ b test config.test=basics # All in basics.test +$ b test config.test=basics # All in basics.testscript $ b test config.test=basics/fox # All in fox $ b test config.test=basics/foo # Only foo $ b test 'config.test=basics/foo basics/fox/bar' # Only foo and bar @@ -1624,7 +1625,7 @@ variable is assigned. You can, however, use variables assigned in the buildfile. For example: \ -include common-$(cxx.target.class).test +include common-$(cxx.target.class).testscript \ \h2#syntax-directive-include|Include| @@ -2827,9 +2828,9 @@ tests. It is also a good idea to give the summary of the group, for example: \ In the same vein, don't repeat the testscript id in group or test ids. For -example, if the above tests were in the \c{greeting.test} testscript, then -using \c{custom-greeting} as the group id would be unnecessarily repetitive -since the id path would then become \c{greeting/custom-greeting/john}, etc. +example, if the above tests were in \c{greeting.testscript}, then using +\c{custom-greeting} as the group id would be unnecessarily repetitive since +the id path would then become \c{greeting/custom-greeting/john}, etc. We quote values that are \i{strings} as opposed to options, file names, paths (unless contain spaces), integers, or boolean. When quoting, use the single diff --git a/tests/bash/testscript b/tests/bash/testscript index 39f247b6..11f50c71 100644 --- a/tests/bash/testscript +++ b/tests/bash/testscript @@ -11,7 +11,7 @@ if ($test.target == $build.host && $build.host.class != 'windows') buildfile = true test.arguments = - .include ../common.test + .include ../common.testscript +cat <<EOI >+build/bootstrap.build using test diff --git a/tests/build/root.build b/tests/build/root.build index 6e4fea97..749e6c3d 100644 --- a/tests/build/root.build +++ b/tests/build/root.build @@ -13,7 +13,7 @@ cxx{*}: extension = cxx # as our $build.path). # import b = build2%exe{b} -test{*}: test = $b +testscript{*}: test = $b # Specify the test target for cross-testing. # diff --git a/tests/buildfile b/tests/buildfile index 092b2ad0..e53cbc93 100644 --- a/tests/buildfile +++ b/tests/buildfile @@ -2,4 +2,4 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -./: {*/ -build/} file{common.test} +./: {*/ -build/} file{common.testscript} diff --git a/tests/cc/libu/testscript b/tests/cc/libu/testscript index 45521419..66424b87 100644 --- a/tests/cc/libu/testscript +++ b/tests/cc/libu/testscript @@ -5,7 +5,7 @@ crosstest = false test.arguments = config.cxx="$recall($cxx.path)" -.include ../../common.test +.include ../../common.testscript +cat <<EOI >+build/bootstrap.build using test diff --git a/tests/cc/modules/testscript b/tests/cc/modules/testscript index 4401bfdd..ea7bd97f 100644 --- a/tests/cc/modules/testscript +++ b/tests/cc/modules/testscript @@ -5,7 +5,7 @@ crosstest = false test.arguments = config.cxx="$recall($cxx.path)" -.include ../../common.test +.include ../../common.testscript +cat <<EOI >+build/bootstrap.build using test diff --git a/tests/cc/preprocessed/testscript b/tests/cc/preprocessed/testscript index 2c20d3f5..853d5634 100644 --- a/tests/cc/preprocessed/testscript +++ b/tests/cc/preprocessed/testscript @@ -5,7 +5,7 @@ crosstest = false test.arguments = config.cxx="$recall($cxx.path)" update -.include ../../common.test +.include ../../common.testscript # Trace filter. # diff --git a/tests/common.test b/tests/common.testscript index 586e7936..369c7984 100644 --- a/tests/common.test +++ b/tests/common.testscript @@ -1,4 +1,4 @@ -# file : tests/common.test +# file : tests/common.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/tests/directive/assert.test b/tests/directive/assert.testscript index 2d705734..ffe6aa0c 100644 --- a/tests/directive/assert.test +++ b/tests/directive/assert.testscript @@ -1,8 +1,8 @@ -# file : tests/directive/assert.test +# file : tests/directive/assert.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript $* <'assert true' : true $* <'assert! false foo' : not-false diff --git a/tests/directive/buildfile b/tests/directive/buildfile index c03a08dc..ac4c7529 100644 --- a/tests/directive/buildfile +++ b/tests/directive/buildfile @@ -2,4 +2,4 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -./: test{*} $b +./: testscript{*} $b diff --git a/tests/directive/run.test b/tests/directive/run.testscript index 30d4a6ae..ba4a413a 100644 --- a/tests/directive/run.test +++ b/tests/directive/run.testscript @@ -1,4 +1,4 @@ -# file : tests/directive/run.test +# file : tests/directive/run.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file @@ -6,7 +6,7 @@ # crosstest = false -.include ../common.test +.include ../common.testscript : no-output : diff --git a/tests/eval/buildfile b/tests/eval/buildfile index 8fa0064e..f7fa2d5f 100644 --- a/tests/eval/buildfile +++ b/tests/eval/buildfile @@ -2,4 +2,4 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -./: test{*} $b +./: testscript{*} $b diff --git a/tests/eval/comma.test b/tests/eval/comma.testscript index 1a36dd14..bb748d16 100644 --- a/tests/eval/comma.test +++ b/tests/eval/comma.testscript @@ -1,10 +1,10 @@ -# file : tests/eval/comma.test +# file : tests/eval/comma.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file # Test value packs (eval-comma). -.include ../common.test +.include ../common.testscript : comma : diff --git a/tests/eval/comp.test b/tests/eval/comp.testscript index c1a4cf7f..481c50bf 100644 --- a/tests/eval/comp.test +++ b/tests/eval/comp.testscript @@ -1,10 +1,10 @@ -# file : tests/eval/comp.test +# file : tests/eval/comp.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file # Test comparison operators (eval-comp). -.include ../common.test +.include ../common.testscript $* <'print (foo == bar)' >'false' : eq-false $* <'print (foo == foo)' >'true' : eq-true diff --git a/tests/eval/or-and.test b/tests/eval/or-and.testscript index 796f92ab..7796f742 100644 --- a/tests/eval/or-and.test +++ b/tests/eval/or-and.testscript @@ -1,10 +1,10 @@ -# file : tests/eval/or-and.test +# file : tests/eval/or-and.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file # Test logical operators (eval-or, eval-and). -.include ../common.test +.include ../common.testscript $* <'print (false || false)' >'false' : or-false $* <'print (false || true)' >'true' : or-true-1 diff --git a/tests/eval/qual.test b/tests/eval/qual.testscript index babd9565..e7bf472b 100644 --- a/tests/eval/qual.test +++ b/tests/eval/qual.testscript @@ -1,10 +1,10 @@ -# file : tests/eval/qual.test +# file : tests/eval/qual.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file # Test qualified name (eval-qual). -.include ../common.test +.include ../common.testscript $* <'print (file{foo}: bar)' >'file{foo}:bar' : target $* <'print (foo/dir{}: bar)' >'dir{foo/}:bar' : scope diff --git a/tests/eval/ternary.test b/tests/eval/ternary.testscript index a2201107..fc405e52 100644 --- a/tests/eval/ternary.test +++ b/tests/eval/ternary.testscript @@ -1,10 +1,10 @@ -# file : tests/eval/ternary.test +# file : tests/eval/ternary.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file # Test the ternary operator (eval-ternary). -.include ../common.test +.include ../common.testscript $* <'print (true ? foo : bar)' >'foo' : true $* <'print (false ? foo : bar)' >'bar' : false diff --git a/tests/eval/value.test b/tests/eval/value.testscript index a3e1d4c5..7cae6e2d 100644 --- a/tests/eval/value.test +++ b/tests/eval/value.testscript @@ -1,10 +1,10 @@ -# file : tests/eval/value.test +# file : tests/eval/value.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file # Test value part of the grammar (eval-value). -.include ../common.test +.include ../common.testscript $* <'print (foo)' >'foo' : value $* <'print ()' >'' : value-empty diff --git a/tests/expansion/buildfile b/tests/expansion/buildfile index c144c232..7a73b9d8 100644 --- a/tests/expansion/buildfile +++ b/tests/expansion/buildfile @@ -2,4 +2,4 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -./: test{*} $b +./: testscript{*} $b diff --git a/tests/expansion/concat.test b/tests/expansion/concat.testscript index baaf1e12..75487b5d 100644 --- a/tests/expansion/concat.test +++ b/tests/expansion/concat.testscript @@ -1,10 +1,10 @@ -# file : tests/expansion/type.test +# file : tests/expansion/type.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file # Test concatenated expansion. -.include ../common.test +.include ../common.testscript : typed-exceptions : diff --git a/tests/expansion/type.test b/tests/expansion/type.testscript index 8899aa37..12204a35 100644 --- a/tests/expansion/type.test +++ b/tests/expansion/type.testscript @@ -1,10 +1,10 @@ -# file : tests/expansion/type.test +# file : tests/expansion/type.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file # Test type propagation during expansion. -.include ../common.test +.include ../common.testscript : var : diff --git a/tests/function/builtin/testscript b/tests/function/builtin/testscript index d15eeb3c..e54fb0fb 100644 --- a/tests/function/builtin/testscript +++ b/tests/function/builtin/testscript @@ -2,7 +2,7 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../../common.test +.include ../../common.testscript : type : diff --git a/tests/function/filesystem/testscript b/tests/function/filesystem/testscript index 7dcfde9b..42c09dba 100644 --- a/tests/function/filesystem/testscript +++ b/tests/function/filesystem/testscript @@ -2,7 +2,7 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../../common.test +.include ../../common.testscript : path-search : diff --git a/tests/function/install/testscript b/tests/function/install/testscript index 73aba00e..e2afc390 100644 --- a/tests/function/install/testscript +++ b/tests/function/install/testscript @@ -2,7 +2,7 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../../common.test +.include ../../common.testscript +cat <<EOI >+build/bootstrap.build using config diff --git a/tests/function/path/testscript b/tests/function/path/testscript index 8446bf02..84a1cc15 100644 --- a/tests/function/path/testscript +++ b/tests/function/path/testscript @@ -2,7 +2,7 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../../common.test +.include ../../common.testscript s = ($cxx.target.class != 'windows' ? '/' : '\') diff --git a/tests/function/process/testscript b/tests/function/process/testscript index f01af6f4..d4fe864f 100644 --- a/tests/function/process/testscript +++ b/tests/function/process/testscript @@ -2,7 +2,7 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../../common.test +.include ../../common.testscript : run : diff --git a/tests/function/regex/testscript b/tests/function/regex/testscript index 28d6c8e8..4d48e040 100644 --- a/tests/function/regex/testscript +++ b/tests/function/regex/testscript @@ -2,7 +2,7 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../../common.test +.include ../../common.testscript : replace : diff --git a/tests/hooks/testscript b/tests/hooks/testscript index f0d5c14e..92c9964e 100644 --- a/tests/hooks/testscript +++ b/tests/hooks/testscript @@ -2,7 +2,7 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript +cat <'print bootstrap' >+build/bootstrap.build +cat <'print root' >=build/root.build diff --git a/tests/in/testscript b/tests/in/testscript index 3e061372..9b4b38ab 100644 --- a/tests/in/testscript +++ b/tests/in/testscript @@ -5,7 +5,7 @@ crosstest = false test.arguments = -.include ../common.test +.include ../common.testscript +cat <<EOI >=build/root.build using in diff --git a/tests/loop/buildfile b/tests/loop/buildfile index e5834924..3807ddfa 100644 --- a/tests/loop/buildfile +++ b/tests/loop/buildfile @@ -2,4 +2,4 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -./: test{*} $b +./: testscript{*} $b diff --git a/tests/loop/for.test b/tests/loop/for.testscript index 66bfc802..6aec1b26 100644 --- a/tests/loop/for.test +++ b/tests/loop/for.testscript @@ -1,10 +1,10 @@ -# file : tests/loop/for.test +# file : tests/loop/for.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file # Test for-loop. -.include ../common.test +.include ../common.testscript : line : diff --git a/tests/name/buildfile b/tests/name/buildfile index 4449a1f6..12532020 100644 --- a/tests/name/buildfile +++ b/tests/name/buildfile @@ -2,4 +2,4 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -./: test{*} $b +./: testscript{*} $b diff --git a/tests/name/cross.test b/tests/name/cross.testscript index 009b8516..d625a2ce 100644 --- a/tests/name/cross.test +++ b/tests/name/cross.testscript @@ -1,8 +1,8 @@ -# file : tests/name/cross.test +# file : tests/name/cross.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript +cat <<EOI >=build/root.build define foo: file diff --git a/tests/name/extension.test b/tests/name/extension.testscript index 160c427b..f9df1737 100644 --- a/tests/name/extension.test +++ b/tests/name/extension.testscript @@ -1,8 +1,8 @@ -# file : tests/name/extension.test +# file : tests/name/extension.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript +cat <<EOI >=build/root.build define txt: file @@ -31,8 +31,8 @@ EOI : specified-default : - touch foo.test.txt; - $* <'./: txt{foo.test...}' + touch foo.testscript.txt; + $* <'./: txt{foo.testscript...}' # Trailing dots are not allowed on Windows. # @@ -70,8 +70,8 @@ EOI : specified-default : - touch foo.test.txt; - $* <'print txt{fo?.test...}' >'txt{foo.test...}' + touch foo.testscript.txt; + $* <'print txt{fo?.testscript...}' >'txt{foo.testscript...}' # Trailing dots are not allowed on Windows. # diff --git a/tests/name/pattern.test b/tests/name/pattern.testscript index 8d8840ca..d40e3a4c 100644 --- a/tests/name/pattern.test +++ b/tests/name/pattern.testscript @@ -1,8 +1,8 @@ -# file : tests/name/pattern.test +# file : tests/name/pattern.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript +cat <<EOI >=build/root.build define txt: file diff --git a/tests/search/dir/testscript b/tests/search/dir/testscript index 24162d71..dc4b3a57 100644 --- a/tests/search/dir/testscript +++ b/tests/search/dir/testscript @@ -4,7 +4,7 @@ test.arguments = 'update(../)' -.include ../../common.test +.include ../../common.testscript # foo/ has no buildfile # bar/ has valid buildfile diff --git a/tests/test/buildfile b/tests/test/buildfile index ae792ed2..699dab95 100644 --- a/tests/test/buildfile +++ b/tests/test/buildfile @@ -2,4 +2,4 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -./: */ file{common.test} +./: */ file{common.testscript} diff --git a/tests/test/common.test b/tests/test/common.testscript index ed874243..e6591872 100644 --- a/tests/test/common.test +++ b/tests/test/common.testscript @@ -1,4 +1,4 @@ -# file : tests/test/common.test +# file : tests/test/common.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/tests/test/config-test/testscript b/tests/test/config-test/testscript index 7aadaf22..a9fba832 100644 --- a/tests/test/config-test/testscript +++ b/tests/test/config-test/testscript @@ -1,4 +1,4 @@ -# file : tests/test/config-build/testscript +# file : tests/test/config-test/testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file @@ -44,9 +44,9 @@ EOI # +mkdir proj/tests/script +cat <<EOI >=proj/tests/script/buildfile -./: test{basics.test} +./: testscript{basics.testscript} EOI -+cat <<EOI >=proj/tests/script/basics.test ++cat <<EOI >=proj/tests/script/basics.testscript echo 'tests/script/basics/foo' >| : foo echo 'tests/script/basics/bar' >| : bar diff --git a/tests/test/script/buildfile b/tests/test/script/buildfile index 4adc9d0c..88784159 100644 --- a/tests/test/script/buildfile +++ b/tests/test/script/buildfile @@ -2,4 +2,4 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -./: */ file{common.test} +./: */ file{common.testscript} diff --git a/tests/test/script/builtin/buildfile b/tests/test/script/builtin/buildfile index 7338d4cb..83ecfd28 100644 --- a/tests/test/script/builtin/buildfile +++ b/tests/test/script/builtin/buildfile @@ -2,4 +2,4 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -./: test{*} file{cp-dir/cp-file} $b +./: testscript{*} file{cp-dir/cp-file} $b diff --git a/tests/test/script/builtin/cat.test b/tests/test/script/builtin/cat.testscript index 69ff5788..b72edb4a 100644 --- a/tests/test/script/builtin/cat.test +++ b/tests/test/script/builtin/cat.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/builtin/cat.test +# file : tests/test/script/builtin/cat.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : in : diff --git a/tests/test/script/builtin/cp.test b/tests/test/script/builtin/cp.testscript index e81b395b..e1b654f3 100644 --- a/tests/test/script/builtin/cp.test +++ b/tests/test/script/builtin/cp.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/builtin/cp.test +# file : tests/test/script/builtin/cp.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : args : diff --git a/tests/test/script/builtin/echo.test b/tests/test/script/builtin/echo.testscript index 28647f45..235a9f79 100644 --- a/tests/test/script/builtin/echo.test +++ b/tests/test/script/builtin/echo.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/builtin/echo.test +# file : tests/test/script/builtin/echo.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : string : diff --git a/tests/test/script/builtin/ln.test b/tests/test/script/builtin/ln.testscript index 8b4c30e5..5216d849 100644 --- a/tests/test/script/builtin/ln.test +++ b/tests/test/script/builtin/ln.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/builtin/ln.test +# file : tests/test/script/builtin/ln.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : args : diff --git a/tests/test/script/builtin/mkdir.test b/tests/test/script/builtin/mkdir.testscript index 92cd2e02..6b082bd4 100644 --- a/tests/test/script/builtin/mkdir.test +++ b/tests/test/script/builtin/mkdir.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/builtin/mkdir.test +# file : tests/test/script/builtin/mkdir.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : dirs : diff --git a/tests/test/script/builtin/mv.test b/tests/test/script/builtin/mv.testscript index 291832ef..321fee55 100644 --- a/tests/test/script/builtin/mv.test +++ b/tests/test/script/builtin/mv.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/builtin/mv.test +# file : tests/test/script/builtin/mv.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : args : diff --git a/tests/test/script/builtin/rm.test b/tests/test/script/builtin/rm.testscript index 3679ff10..3dd2674c 100644 --- a/tests/test/script/builtin/rm.test +++ b/tests/test/script/builtin/rm.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/builtin/rm.test +# file : tests/test/script/builtin/rm.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : no-args : diff --git a/tests/test/script/builtin/rmdir.test b/tests/test/script/builtin/rmdir.testscript index 0e53bde0..99dcaf14 100644 --- a/tests/test/script/builtin/rmdir.test +++ b/tests/test/script/builtin/rmdir.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/builtin/rmdir.test +# file : tests/test/script/builtin/rmdir.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : no-args : diff --git a/tests/test/script/builtin/sed.test b/tests/test/script/builtin/sed.testscript index 71824a17..9db7cb4e 100644 --- a/tests/test/script/builtin/sed.test +++ b/tests/test/script/builtin/sed.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/builtin/sed.test +# file : tests/test/script/builtin/sed.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : arg : diff --git a/tests/test/script/builtin/test.test b/tests/test/script/builtin/test.testscript index 73d89bc8..f49b92b3 100644 --- a/tests/test/script/builtin/test.test +++ b/tests/test/script/builtin/test.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/builtin/test.test +# file : tests/test/script/builtin/test.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : file : diff --git a/tests/test/script/builtin/touch.test b/tests/test/script/builtin/touch.testscript index 04391bdc..d58ed7f4 100644 --- a/tests/test/script/builtin/touch.test +++ b/tests/test/script/builtin/touch.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/builtin/touch.test +# file : tests/test/script/builtin/touch.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : file : diff --git a/tests/test/script/common.test b/tests/test/script/common.testscript index bf9ebba4..b5098188 100644 --- a/tests/test/script/common.test +++ b/tests/test/script/common.testscript @@ -1,4 +1,4 @@ -# file : tests/test/script/common.test +# file : tests/test/script/common.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file @@ -20,7 +20,7 @@ EOI +if! $empty($target) cat <<"EOI" >=build/root.build target = \$src_root/../../$string([name] $target) - test{*}: test = \$target + testscript{*}: test = \$target EOI end @@ -32,5 +32,6 @@ end # automatically becoming dir{./}'s prerequisite. # c = cat >=testscript -b = $0 --serial-stop --quiet --buildfile - test <"'test{testscript}: \$target'" \ +b = $0 --serial-stop --quiet --buildfile - test \ +<"'testscript{testscript}: \$target'" \ &?test/*** diff --git a/tests/test/script/generated/testscript b/tests/test/script/generated/testscript index 6f19fb16..0a28aa0b 100644 --- a/tests/test/script/generated/testscript +++ b/tests/test/script/generated/testscript @@ -4,9 +4,9 @@ test.arguments = test clean -# Note: using common.test from test/, not script/. +# Note: using common.testscript from test/, not script/. # -.include ../../common.test +.include ../../common.testscript # @@ in module # diff --git a/tests/test/script/integration/testscript b/tests/test/script/integration/testscript index 7176e0e5..7bdad546 100644 --- a/tests/test/script/integration/testscript +++ b/tests/test/script/integration/testscript @@ -2,19 +2,19 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -# Note: using common.test from test/, not script/. +# Note: using common.testscript from test/, not script/. # -.include ../../common.test +.include ../../common.testscript : script-files : { - +touch testscript foo.test bar.test + +touch testscript foo.testscript bar.testscript : testscript-and-other : $* <<EOI 2>>/EOE != 0 - ./: ../testscript test{../foo} + ./: ../testscript testscript{../foo} EOI error: both 'testscript' and other names specified for dir{./} EOE @@ -22,7 +22,7 @@ : other-and-testscript : $* <<EOI 2>>/EOE != 0 - ./: test{../foo} ../testscript + ./: testscript{../foo} ../testscript EOI error: both 'testscript' and other names specified for dir{./} EOE @@ -30,7 +30,7 @@ : others : $* <<EOI - ./: test{../foo ../bar} + ./: testscript{../foo ../bar} EOI } @@ -39,31 +39,31 @@ : Note that here we can not use portable path modifier as not all slashes are : path separators. : -touch foo.test; +touch foo.testscript; touch test; $* <<EOI 2>>~%EOE% != 0 -./: test{foo} +./: testscript{foo} EOI %error: working directory test[/\\] is a file/symlink% EOE : wd-exists-before : -touch foo.test; +touch foo.testscript; mkdir test &!test/; $* <<EOI 2>>/EOE -./: test{foo} +./: testscript{foo} EOI warning: working directory test/ exists at the beginning of the test EOE : wd-not-empty-before : -touch foo.test; +touch foo.testscript; mkdir test &!test/; touch test/dummy &!test/dummy; $* <<EOI 2>>/EOE -./: test{foo} +./: testscript{foo} EOI warning: working directory test/ exists and is not empty at the beginning of the test EOE @@ -76,11 +76,11 @@ EOE : scope. Also note that we still have to remove everything after detecting the : failure. : -cat <<EOI >=foo.test; +cat <<EOI >=foo.testscript; touch ../../dummy EOI $* <<EOI 2>>/EOE &test/*** != 0 -./: test{foo} +./: testscript{foo} EOI error: working directory test/ is not empty at the end of the test EOE diff --git a/tests/test/script/runner/buildfile b/tests/test/script/runner/buildfile index 0067ec12..6e8bdd3e 100644 --- a/tests/test/script/runner/buildfile +++ b/tests/test/script/runner/buildfile @@ -2,9 +2,9 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -./: test{*} exe{driver} $b +./: testscript{*} exe{driver} $b -test{*}: target = exe{driver} +testscript{*}: target = exe{driver} import libs = libbutl%lib{butl} exe{driver}: {hxx cxx}{*} $libs diff --git a/tests/test/script/runner/cleanup.test b/tests/test/script/runner/cleanup.testscript index 2d992150..7ea1acd0 100644 --- a/tests/test/script/runner/cleanup.test +++ b/tests/test/script/runner/cleanup.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/runner/cleanup.test +# file : tests/test/script/runner/cleanup.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript b += --no-column diff --git a/tests/test/script/runner/exit.test b/tests/test/script/runner/exit.testscript index 7933203c..9329ae4e 100644 --- a/tests/test/script/runner/exit.test +++ b/tests/test/script/runner/exit.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/runner/exit.test +# file : tests/test/script/runner/exit.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : special : @@ -75,7 +75,7 @@ : execution : : Test that only expected commands are executed. Note that we rely on the fact -: that their execution is performed serially (see ../common.test for details). +: that their execution is performed serially (see ../common.testscript for details). : { : test-scope diff --git a/tests/test/script/runner/expr.test b/tests/test/script/runner/expr.testscript index cfc52775..36c15fd8 100644 --- a/tests/test/script/runner/expr.test +++ b/tests/test/script/runner/expr.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/runner/expr.test +# file : tests/test/script/runner/expr.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : short-circuit : diff --git a/tests/test/script/runner/if.test b/tests/test/script/runner/if.testscript index f22f761f..a625c346 100644 --- a/tests/test/script/runner/if.test +++ b/tests/test/script/runner/if.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/runner/if.test +# file : tests/test/script/runner/if.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : if-branch : diff --git a/tests/test/script/runner/output.test b/tests/test/script/runner/output.testscript index a83c0925..ec9ff920 100644 --- a/tests/test/script/runner/output.test +++ b/tests/test/script/runner/output.testscript @@ -1,4 +1,4 @@ -# file : tests/test/script/runner/output.test +# file : tests/test/script/runner/output.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file @@ -7,7 +7,7 @@ # spread the feature tests among several places. # -.include ../common.test +.include ../common.testscript : after : diff --git a/tests/test/script/runner/pipe.test b/tests/test/script/runner/pipe.testscript index 03d8b2a2..7ef5893b 100644 --- a/tests/test/script/runner/pipe.test +++ b/tests/test/script/runner/pipe.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/runner/pipe.test +# file : tests/test/script/runner/pipe.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript $c <'cat <foo | $* -i 1 >foo' && $b : builtin-to-process $c <'$* -o foo | cat >foo' && $b : process-to-builtin diff --git a/tests/test/script/runner/redirect.test b/tests/test/script/runner/redirect.testscript index 13d72196..21e9d07b 100644 --- a/tests/test/script/runner/redirect.test +++ b/tests/test/script/runner/redirect.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/runner/redirect.test +# file : tests/test/script/runner/redirect.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript b += --no-column @@ -14,7 +14,7 @@ psr = ($cxx.target.class != 'windows' ? '/' : '\\') # Path separator in regex. { cat <'$* -i 1 -e bar <| >| 2>|' >=testscript; cat <<EOI >=buildfile; - test{testscript}: $target + testscript{testscript}: $target EOI $0 --serial-stop --quiet test <foo >foo 2>bar } @@ -144,7 +144,7 @@ psr = ($cxx.target.class != 'windows' ? '/' : '\\') # Path separator in regex. : regex : : Test regex matching. Note that tests that check regex parsing are located - : in regex.test testscript. + : in regex.testscript. : { : match @@ -401,7 +401,7 @@ psr = ($cxx.target.class != 'windows' ? '/' : '\\') # Path separator in regex. : regex : : Test regex matching. Note that tests that check regex parsing are located - : in regex.test testscript. + : in regex.testscript. : { : match diff --git a/tests/test/script/runner/regex.test b/tests/test/script/runner/regex.testscript index 018976ca..46b18727 100644 --- a/tests/test/script/runner/regex.test +++ b/tests/test/script/runner/regex.testscript @@ -1,4 +1,4 @@ -# file : tests/test/script/runner/regex.test +# file : tests/test/script/runner/regex.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file @@ -9,13 +9,13 @@ # # Note that such a tests are separated from ones that check regex matching # specifically (in particular matching failures), The latest ones are located -# in redirect.test testscript. +# in redirect.testscript. # # Also note that the following tests are grouped by features: basic # functionality, flags, portable-path modifier. # -.include ../common.test +.include ../common.testscript : basic : diff --git a/tests/test/script/runner/set.test b/tests/test/script/runner/set.testscript index 2266ae90..b10ce1e6 100644 --- a/tests/test/script/runner/set.test +++ b/tests/test/script/runner/set.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/runner/set.test +# file : tests/test/script/runner/set.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : special : diff --git a/tests/test/script/runner/status.test b/tests/test/script/runner/status.testscript index 86d9ca44..1689a69f 100644 --- a/tests/test/script/runner/status.test +++ b/tests/test/script/runner/status.testscript @@ -1,8 +1,8 @@ -# file : tests/test/script/runner/status.test +# file : tests/test/script/runner/status.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript b += --no-column diff --git a/tests/test/simple/generated/testscript b/tests/test/simple/generated/testscript index 61258b0d..08bd3e36 100644 --- a/tests/test/simple/generated/testscript +++ b/tests/test/simple/generated/testscript @@ -4,7 +4,7 @@ test.arguments = test clean -.include ../../common.test +.include ../../common.testscript # @@ in module # diff --git a/tests/value/buildfile b/tests/value/buildfile index 1ab26d57..a43074c9 100644 --- a/tests/value/buildfile +++ b/tests/value/buildfile @@ -2,4 +2,4 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -./: test{*} $b +./: testscript{*} $b diff --git a/tests/value/concat.test b/tests/value/concat.testscript index 79f004c1..581c3ad5 100644 --- a/tests/value/concat.test +++ b/tests/value/concat.testscript @@ -1,8 +1,8 @@ -# file : tests/value/concat.test +# file : tests/value/concat.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../common.test +.include ../common.testscript : dir_path : diff --git a/tests/value/reverse.test b/tests/value/reverse.testscript index 9ea9d09b..6294d3f7 100644 --- a/tests/value/reverse.test +++ b/tests/value/reverse.testscript @@ -1,11 +1,11 @@ -# file : tests/value/reverse.test +# file : tests/value/reverse.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file # Test reversal to canonical/original representation. # -.include ../common.test +.include ../common.testscript : name : diff --git a/tests/variable/override/testscript b/tests/variable/override/testscript index 591fc19d..00ffdb98 100644 --- a/tests/variable/override/testscript +++ b/tests/variable/override/testscript @@ -2,7 +2,7 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../../common.test +.include ../../common.testscript : cache-invalidation : diff --git a/tests/variable/prerequisite-specific/testscript b/tests/variable/prerequisite-specific/testscript index d0ce5e02..1c7e7bd5 100644 --- a/tests/variable/prerequisite-specific/testscript +++ b/tests/variable/prerequisite-specific/testscript @@ -2,7 +2,7 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../../common.test +.include ../../common.testscript # There is currently no support for expanding prerequisite-specific variables # (since there is no way to id a prerequisite) so we use dump. diff --git a/tests/variable/scope-specific/testscript b/tests/variable/scope-specific/testscript index 2f519d26..5f9a05d8 100644 --- a/tests/variable/scope-specific/testscript +++ b/tests/variable/scope-specific/testscript @@ -2,7 +2,7 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../../common.test +.include ../../common.testscript : basic-line : diff --git a/tests/variable/target-specific/testscript b/tests/variable/target-specific/testscript index 8d9917cb..497c8636 100644 --- a/tests/variable/target-specific/testscript +++ b/tests/variable/target-specific/testscript @@ -2,7 +2,7 @@ # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -.include ../../common.test +.include ../../common.testscript : basic-line : diff --git a/unit-tests/cc/lexer/buildfile b/unit-tests/cc/lexer/buildfile index bf7c1c58..4aa8b515 100644 --- a/unit-tests/cc/lexer/buildfile +++ b/unit-tests/cc/lexer/buildfile @@ -3,4 +3,4 @@ # license : MIT; see accompanying LICENSE file include ../../../build2/ -exe{driver}: {hxx cxx}{*} ../../../build2/libu{b} test{*} +exe{driver}: {hxx cxx}{*} ../../../build2/libu{b} testscript{*} diff --git a/unit-tests/cc/lexer/char-literal.test b/unit-tests/cc/lexer/char-literal.testscript index 6253096c..dac66e2c 100644 --- a/unit-tests/cc/lexer/char-literal.test +++ b/unit-tests/cc/lexer/char-literal.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/cc/lexer/char-literal.test +# file : unit-tests/cc/lexer/char-literal.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/cc/lexer/comment.test b/unit-tests/cc/lexer/comment.testscript index 2b5d81e7..d4ad675f 100644 --- a/unit-tests/cc/lexer/comment.test +++ b/unit-tests/cc/lexer/comment.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/cc/lexer/comment.test +# file : unit-tests/cc/lexer/comment.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/cc/lexer/line.test b/unit-tests/cc/lexer/line.testscript index 83ebbebf..01961ebd 100644 --- a/unit-tests/cc/lexer/line.test +++ b/unit-tests/cc/lexer/line.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/cc/lexer/line.test +# file : unit-tests/cc/lexer/line.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/cc/lexer/number.test b/unit-tests/cc/lexer/number.testscript index 73360378..cb82d5f2 100644 --- a/unit-tests/cc/lexer/number.test +++ b/unit-tests/cc/lexer/number.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/cc/lexer/number.test +# file : unit-tests/cc/lexer/number.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/cc/lexer/preprocessor.test b/unit-tests/cc/lexer/preprocessor.testscript index fbe578db..1d86115d 100644 --- a/unit-tests/cc/lexer/preprocessor.test +++ b/unit-tests/cc/lexer/preprocessor.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/cc/lexer/preprocessor.test +# file : unit-tests/cc/lexer/preprocessor.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/cc/lexer/raw-string-literal.test b/unit-tests/cc/lexer/raw-string-literal.testscript index 09b54b59..df475ef1 100644 --- a/unit-tests/cc/lexer/raw-string-literal.test +++ b/unit-tests/cc/lexer/raw-string-literal.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/cc/lexer/raw-string-literal.test +# file : unit-tests/cc/lexer/raw-string-literal.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/cc/lexer/string-literal.test b/unit-tests/cc/lexer/string-literal.testscript index b21b1d2d..e5eb189c 100644 --- a/unit-tests/cc/lexer/string-literal.test +++ b/unit-tests/cc/lexer/string-literal.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/cc/lexer/string-literal.test +# file : unit-tests/cc/lexer/string-literal.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/cc/parser/buildfile b/unit-tests/cc/parser/buildfile index c01c1c0d..fce77f49 100644 --- a/unit-tests/cc/parser/buildfile +++ b/unit-tests/cc/parser/buildfile @@ -3,4 +3,4 @@ # license : MIT; see accompanying LICENSE file include ../../../build2/ -exe{driver}: {hxx cxx}{*} ../../../build2/libu{b} test{*} +exe{driver}: {hxx cxx}{*} ../../../build2/libu{b} testscript{*} diff --git a/unit-tests/cc/parser/module.test b/unit-tests/cc/parser/module.testscript index 65186cdd..c6a7e31f 100644 --- a/unit-tests/cc/parser/module.test +++ b/unit-tests/cc/parser/module.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/cc/parser/module.test +# file : unit-tests/cc/parser/module.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/function/buildfile b/unit-tests/function/buildfile index a3eb72f3..d318351a 100644 --- a/unit-tests/function/buildfile +++ b/unit-tests/function/buildfile @@ -3,4 +3,4 @@ # license : MIT; see accompanying LICENSE file include ../../build2/ -exe{driver}: {hxx cxx}{*} ../../build2/libu{b} test{*} +exe{driver}: {hxx cxx}{*} ../../build2/libu{b} testscript{*} diff --git a/unit-tests/function/call.test b/unit-tests/function/call.testscript index 3dd9a85d..4bc58972 100644 --- a/unit-tests/function/call.test +++ b/unit-tests/function/call.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/function/call.test +# file : unit-tests/function/call.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/function/syntax.test b/unit-tests/function/syntax.testscript index 4620e6aa..c9c56d3e 100644 --- a/unit-tests/function/syntax.test +++ b/unit-tests/function/syntax.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/function/syntax.test +# file : unit-tests/function/syntax.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/lexer/buildfile b/unit-tests/lexer/buildfile index 2e149797..74340182 100644 --- a/unit-tests/lexer/buildfile +++ b/unit-tests/lexer/buildfile @@ -3,4 +3,4 @@ # license : MIT; see accompanying LICENSE file include ../../build2/ -exe{driver}: {hxx cxx}{*} ../../build2/libu{b} test{*} +exe{driver}: {hxx cxx}{*} ../../build2/libu{b} testscript{*} diff --git a/unit-tests/lexer/buildspec.test b/unit-tests/lexer/buildspec.testscript index 9aa0f551..d3dd6605 100644 --- a/unit-tests/lexer/buildspec.test +++ b/unit-tests/lexer/buildspec.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/lexer/buildspec.test +# file : unit-tests/lexer/buildspec.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/lexer/comment.test b/unit-tests/lexer/comment.testscript index 8e0ef2ea..44aee111 100644 --- a/unit-tests/lexer/comment.test +++ b/unit-tests/lexer/comment.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/lexer/comment.test +# file : unit-tests/lexer/comment.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/lexer/eval.test b/unit-tests/lexer/eval.testscript index 4bd33c4a..f09eed4a 100644 --- a/unit-tests/lexer/eval.test +++ b/unit-tests/lexer/eval.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/lexer/eval.test +# file : unit-tests/lexer/eval.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/lexer/quoting.test b/unit-tests/lexer/quoting.testscript index 708e904c..8543a677 100644 --- a/unit-tests/lexer/quoting.test +++ b/unit-tests/lexer/quoting.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/lexer/quoting.test +# file : unit-tests/lexer/quoting.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/lexer/buildfile b/unit-tests/test/script/lexer/buildfile index 34c5d9fe..bbfc0322 100644 --- a/unit-tests/test/script/lexer/buildfile +++ b/unit-tests/test/script/lexer/buildfile @@ -3,4 +3,4 @@ # license : MIT; see accompanying LICENSE file include ../../../../build2/ -exe{driver}: {hxx cxx}{*} ../../../../build2/libu{b} test{*} +exe{driver}: {hxx cxx}{*} ../../../../build2/libu{b} testscript{*} diff --git a/unit-tests/test/script/lexer/command-expansion.test b/unit-tests/test/script/lexer/command-expansion.testscript index 88d7ced6..228fb617 100644 --- a/unit-tests/test/script/lexer/command-expansion.test +++ b/unit-tests/test/script/lexer/command-expansion.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/lexer/command-expansion.test +# file : unit-tests/test/script/lexer/command-expansion.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/lexer/command-line.test b/unit-tests/test/script/lexer/command-line.testscript index 0b396b8e..f84bc865 100644 --- a/unit-tests/test/script/lexer/command-line.test +++ b/unit-tests/test/script/lexer/command-line.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/lexer/command-line.test +# file : unit-tests/test/script/lexer/command-line.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/lexer/description-line.test b/unit-tests/test/script/lexer/description-line.testscript index 5f2ea13a..e14c8a02 100644 --- a/unit-tests/test/script/lexer/description-line.test +++ b/unit-tests/test/script/lexer/description-line.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/lexer/description-line.test +# file : unit-tests/test/script/lexer/description-line.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/lexer/first-token.test b/unit-tests/test/script/lexer/first-token.testscript index d754d691..0484b6d4 100644 --- a/unit-tests/test/script/lexer/first-token.test +++ b/unit-tests/test/script/lexer/first-token.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/lexer/first-token.test +# file : unit-tests/test/script/lexer/first-token.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/lexer/second-token.test b/unit-tests/test/script/lexer/second-token.testscript index 8b3f4529..d7cc5011 100644 --- a/unit-tests/test/script/lexer/second-token.test +++ b/unit-tests/test/script/lexer/second-token.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/lexer/second-token.test +# file : unit-tests/test/script/lexer/second-token.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/lexer/variable-line.test b/unit-tests/test/script/lexer/variable-line.testscript index 68d3a71a..b28bc93a 100644 --- a/unit-tests/test/script/lexer/variable-line.test +++ b/unit-tests/test/script/lexer/variable-line.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/lexer/variable-line.test +# file : unit-tests/test/script/lexer/variable-line.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/lexer/variable.test b/unit-tests/test/script/lexer/variable.testscript index 60106ab4..b4f793e1 100644 --- a/unit-tests/test/script/lexer/variable.test +++ b/unit-tests/test/script/lexer/variable.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/lexer/variable.test +# file : unit-tests/test/script/lexer/variable.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/parser/buildfile b/unit-tests/test/script/parser/buildfile index ee0e26db..173b15d8 100644 --- a/unit-tests/test/script/parser/buildfile +++ b/unit-tests/test/script/parser/buildfile @@ -3,4 +3,4 @@ # license : MIT; see accompanying LICENSE file include ../../../../build2/ -exe{driver}: {hxx cxx}{*} ../../../../build2/libu{b} test{*} +exe{driver}: {hxx cxx}{*} ../../../../build2/libu{b} testscript{*} diff --git a/unit-tests/test/script/parser/cleanup.test b/unit-tests/test/script/parser/cleanup.testscript index 1b43c90e..b429f5dd 100644 --- a/unit-tests/test/script/parser/cleanup.test +++ b/unit-tests/test/script/parser/cleanup.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/cleanup.test +# file : unit-tests/test/script/parser/cleanup.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/parser/command-if.test b/unit-tests/test/script/parser/command-if.testscript index 4936553f..264c522a 100644 --- a/unit-tests/test/script/parser/command-if.test +++ b/unit-tests/test/script/parser/command-if.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/command-if.test +# file : unit-tests/test/script/parser/command-if.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/parser/command-re-parse.test b/unit-tests/test/script/parser/command-re-parse.testscript index a6ef6d33..b137b0e1 100644 --- a/unit-tests/test/script/parser/command-re-parse.test +++ b/unit-tests/test/script/parser/command-re-parse.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/command-re-parse.test +# file : unit-tests/test/script/parser/command-re-parse.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/parser/description.test b/unit-tests/test/script/parser/description.testscript index e651a4a0..1945cd23 100644 --- a/unit-tests/test/script/parser/description.test +++ b/unit-tests/test/script/parser/description.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/description.test +# file : unit-tests/test/script/parser/description.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/parser/directive.test b/unit-tests/test/script/parser/directive.testscript index 66bae0d7..82fc471b 100644 --- a/unit-tests/test/script/parser/directive.test +++ b/unit-tests/test/script/parser/directive.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/directive.test +# file : unit-tests/test/script/parser/directive.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file @@ -6,11 +6,11 @@ : $* <<EOI >>EOO x = x -".include" foo.test -\.include foo.test +".include" foo.testscript +\.include foo.testscript EOI -.include foo.test -.include foo.test +.include foo.testscript +.include foo.testscript EOO : expected-name @@ -31,26 +31,26 @@ EOE : separated : -touch foo.test; +touch foo.testscript; $* <<EOI -. include foo.test +. include foo.testscript EOI : not-separated : -touch foo.test; +touch foo.testscript; $* <<EOI -x = foo.test +x = foo.testscript .include$x EOI : var-expansion : -cat <<EOI >="foo-$(build.verson.project).test"; +cat <<EOI >="foo-$(build.verson.project).testscript"; cmd EOI $* <<EOI >>EOO -.include "foo-$(build.verson.project).test" +.include "foo-$(build.verson.project).testscript" EOI cmd EOO @@ -59,7 +59,7 @@ EOO : $* <<EOI 2>>EOE != 0 cmd; -.include foo.test +.include foo.testscript EOI testscript:2:1: error: directive after ';' EOE @@ -67,8 +67,8 @@ EOE : semi-after : $* <<EOI 2>>EOE != 0 -.include foo.test; +.include foo.testscript; cmd EOI -testscript:1:18: error: ';' after directive +testscript:1:24: error: ';' after directive EOE diff --git a/unit-tests/test/script/parser/exit.test b/unit-tests/test/script/parser/exit.testscript index 3c796f11..af3707d6 100644 --- a/unit-tests/test/script/parser/exit.test +++ b/unit-tests/test/script/parser/exit.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/exit.test +# file : unit-tests/test/script/parser/exit.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/parser/expansion.test b/unit-tests/test/script/parser/expansion.testscript index e161c2c2..710d7a1b 100644 --- a/unit-tests/test/script/parser/expansion.test +++ b/unit-tests/test/script/parser/expansion.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/expansion.test +# file : unit-tests/test/script/parser/expansion.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/parser/here-document.test b/unit-tests/test/script/parser/here-document.testscript index 9aebed45..ad2be7da 100644 --- a/unit-tests/test/script/parser/here-document.test +++ b/unit-tests/test/script/parser/here-document.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/here-document.test +# file : unit-tests/test/script/parser/here-document.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/parser/here-string.test b/unit-tests/test/script/parser/here-string.testscript index f5e3c940..a9e42c03 100644 --- a/unit-tests/test/script/parser/here-string.test +++ b/unit-tests/test/script/parser/here-string.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/here-string.test +# file : unit-tests/test/script/parser/here-string.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/parser/include.test b/unit-tests/test/script/parser/include.testscript index 99e17dee..5e31f0d2 100644 --- a/unit-tests/test/script/parser/include.test +++ b/unit-tests/test/script/parser/include.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/include.test +# file : unit-tests/test/script/parser/include.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file @@ -11,27 +11,27 @@ EOI : empty : -touch foo.test; +touch foo.testscript; $* <<EOI -.include foo.test -.include --once foo.test +.include foo.testscript +.include --once foo.testscript EOI : one : -cat <"cmd" >=foo.test; +cat <"cmd" >=foo.testscript; $* <<EOI >>EOO -.include foo.test +.include foo.testscript EOI cmd EOO : multiple : -cat <"cmd foo" >=foo.test; -cat <"cmd bar" >=bar.test; +cat <"cmd foo" >=foo.testscript; +cat <"cmd bar" >=bar.testscript; $* <<EOI >>EOO -.include foo.test bar.test +.include foo.testscript bar.testscript EOI cmd foo cmd bar @@ -39,14 +39,14 @@ EOO : once : -cat <"cmd" >=foo.test; +cat <"cmd" >=foo.testscript; $* <<EOI >>EOO -.include foo.test +.include foo.testscript x -.include --once foo.test -.include --once bar/../foo.test +.include --once foo.testscript +.include --once bar/../foo.testscript y -.include ../once/foo.test +.include ../once/foo.testscript EOI cmd x @@ -56,14 +56,14 @@ EOO : group-id : -cat <<EOI >=foo.test; +cat <<EOI >=foo.testscript; { x = b } EOI $* -s -i <<EOI >>EOO x = a -.include foo.test +.include foo.testscript EOI { { # 2-foo-1 @@ -73,12 +73,12 @@ EOO : test-id : -cat <<EOI >=foo.test; +cat <<EOI >=foo.testscript; cmd EOI $* -s -i <<EOI >>EOO x = a -.include foo.test +.include foo.testscript EOI { { # 2-foo-1 @@ -98,7 +98,7 @@ EOE : unable-open : $* <<EOI 2>>~/EOE/ != 0 -.include foo.test +.include foo.testscript EOI -/testscript:1:2: error: unable to read testscript foo.test: .+/ +/testscript:1:2: error: unable to read testscript foo.testscript: .+/ EOE diff --git a/unit-tests/test/script/parser/pipe-expr.test b/unit-tests/test/script/parser/pipe-expr.testscript index 3b06da3f..70861815 100644 --- a/unit-tests/test/script/parser/pipe-expr.test +++ b/unit-tests/test/script/parser/pipe-expr.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/pipe-expr.test +# file : unit-tests/test/script/parser/pipe-expr.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/parser/pre-parse.test b/unit-tests/test/script/parser/pre-parse.testscript index b1f42090..d37f9724 100644 --- a/unit-tests/test/script/parser/pre-parse.test +++ b/unit-tests/test/script/parser/pre-parse.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/pre-parse.test +# file : unit-tests/test/script/parser/pre-parse.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/parser/redirect.test b/unit-tests/test/script/parser/redirect.testscript index 766d6cc2..4001a3bd 100644 --- a/unit-tests/test/script/parser/redirect.test +++ b/unit-tests/test/script/parser/redirect.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/redirect.test +# file : unit-tests/test/script/parser/redirect.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/parser/regex.test b/unit-tests/test/script/parser/regex.testscript index d8ebb684..67832ebd 100644 --- a/unit-tests/test/script/parser/regex.test +++ b/unit-tests/test/script/parser/regex.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/regex.test +# file : unit-tests/test/script/parser/regex.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/parser/scope-if.test b/unit-tests/test/script/parser/scope-if.testscript index c0cf6fbb..c76fab7f 100644 --- a/unit-tests/test/script/parser/scope-if.test +++ b/unit-tests/test/script/parser/scope-if.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/scope-if.test +# file : unit-tests/test/script/parser/scope-if.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file diff --git a/unit-tests/test/script/parser/scope.test b/unit-tests/test/script/parser/scope.testscript index 21a6f503..721e455d 100644 --- a/unit-tests/test/script/parser/scope.test +++ b/unit-tests/test/script/parser/scope.testscript @@ -1,9 +1,9 @@ -# file : unit-tests/test/script/parser/scope.test +# file : unit-tests/test/script/parser/scope.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file -$* testscript <'cmd $@' >"cmd 1" : id-testscript -$* foo.test <'cmd $@' >"cmd foo/1" : id +$* testscript <'cmd $@' >"cmd 1" : id-testscript +$* foo.testscript <'cmd $@' >"cmd foo/1" : id : wd-testscript : @@ -11,7 +11,7 @@ $* testscript <'cmd "$~"' >~"%cmd '?.+[/\\\\]test-driver[/\\\\]1'?%" : wd : -$* foo.test <'cmd "$~"' >~"%cmd '?.+[/\\\\]test-driver[/\\\\]foo[/\\\\]1'?%" +$* foo.testscript <'cmd "$~"' >~"%cmd '?.+[/\\\\]test-driver[/\\\\]foo[/\\\\]1'?%" : group : diff --git a/unit-tests/test/script/parser/setup-teardown.test b/unit-tests/test/script/parser/setup-teardown.testscript index f9cbb04e..12fde8c7 100644 --- a/unit-tests/test/script/parser/setup-teardown.test +++ b/unit-tests/test/script/parser/setup-teardown.testscript @@ -1,4 +1,4 @@ -# file : unit-tests/test/script/parser/setup-teardown.test +# file : unit-tests/test/script/parser/setup-teardown.testscript # copyright : Copyright (c) 2014-2018 Code Synthesis Ltd # license : MIT; see accompanying LICENSE file |