diff options
Diffstat (limited to 'tests/test')
-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 |
31 files changed, 77 insertions, 76 deletions
diff --git a/tests/test/buildfile b/tests/test/buildfile index ae792ed..699dab9 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 ed87424..e659187 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 7aadaf2..a9fba83 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 4adc9d0..8878415 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 7338d4c..83ecfd2 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 69ff578..b72edb4 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 e81b395..e1b654f 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 28647f4..235a9f7 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 8b4c30e..5216d84 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 92cd2e0..6b082bd 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 291832e..321fee5 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 3679ff1..3dd2674 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 0e53bde..99dcaf1 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 71824a1..9db7cb4 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 73d89bc..f49b92b 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 04391bd..d58ed7f 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 bf9ebba..b509818 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 6f19fb1..0a28aa0 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 7176e0e..7bdad54 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 0067ec1..6e8bdd3 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 2d99215..7ea1acd 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 7933203..9329ae4 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 cfc5277..36c15fd 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 f22f761..a625c34 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 a83c092..ec9ff92 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 03d8b2a..7ef5893 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 13d7219..21e9d07 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 018976c..46b1872 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 2266ae9..b10ce1e 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 86d9ca4..1689a69 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 61258b0..08bd3e3 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 # |