summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/AddOption/longopts.py9
-rw-r--r--test/AddOption/multi-arg.py2
-rw-r--r--test/Removed/debug-dtree.py9
-rw-r--r--test/Removed/debug-nomemoizer.py9
-rw-r--r--test/Removed/debug-stree.py9
-rw-r--r--test/Removed/debug-tree.py9
-rw-r--r--test/SCONSFLAGS.py9
-rw-r--r--test/option/option--duplicate.py7
-rw-r--r--test/option/option--experimental.py2
-rw-r--r--test/option/option--tree.py9
-rw-r--r--test/option/option-unknown.py11
-rw-r--r--test/option/option_profile.py11
12 files changed, 44 insertions, 52 deletions
diff --git a/test/AddOption/longopts.py b/test/AddOption/longopts.py
index 48c3502..e0c0df4 100644
--- a/test/AddOption/longopts.py
+++ b/test/AddOption/longopts.py
@@ -1,6 +1,8 @@
#!/usr/bin/env python
#
-# __COPYRIGHT__
+# MIT License
+#
+# Copyright The SCons Foundation
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
@@ -20,9 +22,6 @@
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-#
-
-__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
"""
Verifies that the default name matching of optparse for long options
@@ -55,7 +54,7 @@ test.run('-Q -q . --myarg=helloworld',
test.run('-Q -q . --myargumen=helloworld', status=2,
stdout="myargument: gully\nmyarg: balla\n",
stderr="""\
-usage: scons [OPTION] [TARGET] ...
+usage: scons [OPTIONS] [VARIABLES] [TARGETS]
SCons Error: no such option: '--myargumen'. Did you mean '--myargument'?
""")
diff --git a/test/AddOption/multi-arg.py b/test/AddOption/multi-arg.py
index 44928c4..1a71cfe 100644
--- a/test/AddOption/multi-arg.py
+++ b/test/AddOption/multi-arg.py
@@ -56,7 +56,7 @@ test.run(
'-Q -q . --extras A',
status=2,
stderr="""\
-usage: scons [OPTION] [TARGET] ...
+usage: scons [OPTIONS] [VARIABLES] [TARGETS]
SCons Error: --extras option requires 2 arguments
""",
diff --git a/test/Removed/debug-dtree.py b/test/Removed/debug-dtree.py
index a016f96..0cd41b3 100644
--- a/test/Removed/debug-dtree.py
+++ b/test/Removed/debug-dtree.py
@@ -1,6 +1,8 @@
#!/usr/bin/env python
#
-# __COPYRIGHT__
+# MIT License
+#
+# Copyright The SCons Foundation
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
@@ -20,9 +22,6 @@
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-#
-
-__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
"""
Test that the --debug=dtree option fails with expected exception
@@ -37,7 +36,7 @@ test = TestSCons.TestSCons()
test.write('SConstruct', "")
-expect = r"""usage: scons [OPTION] [TARGET] ...
+expect = r"""usage: scons [OPTIONS] [VARIABLES] [TARGETS]
SCons Error: `dtree' is not a valid debug option type ; please use --tree=derived instead
"""
diff --git a/test/Removed/debug-nomemoizer.py b/test/Removed/debug-nomemoizer.py
index a830a88..827ace6 100644
--- a/test/Removed/debug-nomemoizer.py
+++ b/test/Removed/debug-nomemoizer.py
@@ -1,6 +1,8 @@
#!/usr/bin/env python
#
-# __COPYRIGHT__
+# MIT License
+#
+# Copyright The SCons Foundation
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
@@ -20,9 +22,6 @@
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-#
-
-__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
"""
Test that the --debug=nomemoizer option fails with expected exception
@@ -37,7 +36,7 @@ test = TestSCons.TestSCons()
test.write('SConstruct', "")
-expect=r"""usage: scons [OPTION] [TARGET] ...
+expect=r"""usage: scons [OPTIONS] [VARIABLES] [TARGETS]
SCons Error: `nomemoizer' is not a valid debug option type ; there is no replacement
"""
diff --git a/test/Removed/debug-stree.py b/test/Removed/debug-stree.py
index 60ce4f2..81d21f7 100644
--- a/test/Removed/debug-stree.py
+++ b/test/Removed/debug-stree.py
@@ -1,6 +1,8 @@
#!/usr/bin/env python
#
-# __COPYRIGHT__
+# MIT License
+#
+# Copyright The SCons Foundation
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
@@ -20,9 +22,6 @@
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-#
-
-__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
"""
Test that the --debug=stree option fails with expected exception
@@ -37,7 +36,7 @@ test = TestSCons.TestSCons()
test.write('SConstruct', "")
-expect = r"""usage: scons [OPTION] [TARGET] ...
+expect = r"""usage: scons [OPTIONS] [VARIABLES] [TARGETS]
SCons Error: `stree' is not a valid debug option type ; please use --tree=all,status instead
"""
diff --git a/test/Removed/debug-tree.py b/test/Removed/debug-tree.py
index 06287de..81063da 100644
--- a/test/Removed/debug-tree.py
+++ b/test/Removed/debug-tree.py
@@ -1,6 +1,8 @@
#!/usr/bin/env python
#
-# __COPYRIGHT__
+# MIT License
+#
+# Copyright The SCons Foundation
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
@@ -20,9 +22,6 @@
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-#
-
-__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
"""
Test that the --debug=tree option fails with expected exception
@@ -38,7 +37,7 @@ test = TestSCons.TestSCons()
test.write('SConstruct', "")
-expect = r"""usage: scons [OPTION] [TARGET] ...
+expect = r"""usage: scons [OPTIONS] [VARIABLES] [TARGETS]
SCons Error: `tree' is not a valid debug option type ; please use --tree=all instead
"""
diff --git a/test/SCONSFLAGS.py b/test/SCONSFLAGS.py
index db866e8..6b2ea8b 100644
--- a/test/SCONSFLAGS.py
+++ b/test/SCONSFLAGS.py
@@ -1,6 +1,8 @@
#!/usr/bin/env python
#
-# __COPYRIGHT__
+# MIT License
+#
+# Copyright The SCons Foundation
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
@@ -20,9 +22,6 @@
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-#
-
-__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
import os
@@ -65,7 +64,7 @@ test.must_contain_all_lines(test.stdout(), ['-H, --help-options'])
os.environ['SCONSFLAGS'] = '-Z'
-expect = r"""usage: scons [OPTION] [TARGET] ...
+expect = r"""usage: scons [OPTIONS] [VARIABLES] [TARGETS]
SCons Error: no such option: -Z
"""
diff --git a/test/option/option--duplicate.py b/test/option/option--duplicate.py
index 91dc61c..74de64b 100644
--- a/test/option/option--duplicate.py
+++ b/test/option/option--duplicate.py
@@ -1,6 +1,8 @@
#!/usr/bin/env python
#
-# __COPYRIGHT__
+# MIT License
+#
+# Copyright The SCons Foundation
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
@@ -20,7 +22,6 @@
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-#
"""
This tests the --duplicate command line option, and the duplicate
@@ -125,7 +126,7 @@ type='copy'
RunTest('copy', type, bss)
test.run(arguments='--duplicate=nonsense', status=2, stderr="""\
-usage: scons [OPTION] [TARGET] ...
+usage: scons [OPTIONS] [VARIABLES] [TARGETS]
SCons Error: `nonsense' is not a valid duplication option type, try:
hard-soft-copy, soft-hard-copy, hard-copy, soft-copy, copy
diff --git a/test/option/option--experimental.py b/test/option/option--experimental.py
index 2e06dc3..51f3546 100644
--- a/test/option/option--experimental.py
+++ b/test/option/option--experimental.py
@@ -48,7 +48,7 @@ Experimental=%s
stdout=test.wrap_stdout(read_str=read_string, build_str="scons: `.' is up to date.\n"))
test.run(arguments='--experimental=warp_drive',
- stderr="""usage: scons [OPTION] [TARGET] ...
+ stderr="""usage: scons [OPTIONS] [VARIABLES] [TARGETS]
SCons Error: option --experimental: invalid choice: 'warp_drive' (choose from 'all','none','ninja','transporter','warp_speed')
""",
diff --git a/test/option/option--tree.py b/test/option/option--tree.py
index 5192ac0..b575fe5 100644
--- a/test/option/option--tree.py
+++ b/test/option/option--tree.py
@@ -1,6 +1,8 @@
#!/usr/bin/env python
#
-# __COPYRIGHT__
+# MIT License
+#
+# Copyright The SCons Foundation
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
@@ -20,9 +22,6 @@
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-#
-
-__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
import TestSCons
@@ -37,7 +36,7 @@ test.run(arguments='-Q --tree=prune',
""")
test.run(arguments='-Q --tree=foofoo',
- stderr="""usage: scons [OPTION] [TARGET] ...
+ stderr="""usage: scons [OPTIONS] [VARIABLES] [TARGETS]
SCons Error: `foofoo' is not a valid --tree option type, try:
all, derived, prune, status, linedraw
diff --git a/test/option/option-unknown.py b/test/option/option-unknown.py
index 8b42762..62928be 100644
--- a/test/option/option-unknown.py
+++ b/test/option/option-unknown.py
@@ -1,6 +1,8 @@
#!/usr/bin/env python
#
-# __COPYRIGHT__
+# MIT License
+#
+# Copyright The SCons Foundation
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
@@ -20,9 +22,6 @@
# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-#
-
-__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
import TestSCons
@@ -31,14 +30,14 @@ test = TestSCons.TestSCons()
test.write('SConstruct', "")
test.run(arguments = '-Z',
- stderr = """usage: scons [OPTION] [TARGET] ...
+ stderr = """usage: scons [OPTIONS] [VARIABLES] [TARGETS]
SCons Error: no such option: -Z
""",
status = 2)
test.run(arguments = '--ZizzerZazzerZuzz',
- stderr = """usage: scons [OPTION] [TARGET] ...
+ stderr = """usage: scons [OPTIONS] [VARIABLES] [TARGETS]
SCons Error: no such option: --ZizzerZazzerZuzz
""",
diff --git a/test/option/option_profile.py b/test/option/option_profile.py
index 8c7d80a..19e68f6 100644
--- a/test/option/option_profile.py
+++ b/test/option/option_profile.py
@@ -1,6 +1,8 @@
#!/usr/bin/env python
#
-# __COPYRIGHT__
+# MIT License
+#
+# Copyright The SCons Foundation
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
@@ -21,9 +23,6 @@
# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-
-__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
-
import contextlib
import sys
from io import StringIO
@@ -47,7 +46,7 @@ test.write('file.in', "file.in\n")
scons_prof = test.workpath('scons.prof')
test.run(arguments = "--profile=%s -h" % scons_prof)
-test.must_contain_all_lines(test.stdout(), ['usage: scons [OPTION]'])
+test.must_contain_all_lines(test.stdout(), ['usage: scons [OPTIONS] [VARIABLES] [TARGETS]'])
try:
save_stdout = sys.stdout
@@ -89,7 +88,7 @@ scons_prof = test.workpath('scons3.prof')
test.run(arguments = "--profile %s --debug=memory -h" % scons_prof)
expect = [
- 'usage: scons [OPTION]',
+ 'usage: scons [OPTIONS] [VARIABLES] [TARGETS]',
'Options:'
]
test.must_contain_all_lines(test.stdout(), expect)