summaryrefslogtreecommitdiff
path: root/test/Configure
diff options
context:
space:
mode:
authorSteven Knight <knight@baldmt.com>2009-02-06 14:55:23 +0000
committerSteven Knight <knight@baldmt.com>2009-02-06 14:55:23 +0000
commita4d9a13b7a85f2c7f55fc409056e3b9628902022 (patch)
tree978573b4ff11f036428c0a08a89085313ad990fa /test/Configure
parentf706866a1d840a6fc1251ad6c62e137c240967fd (diff)
downloadscons-a4d9a13b7a85f2c7f55fc409056e3b9628902022.tar.gz
Commonize new string-search-in-output methods:
test.must_contain_all_lines() test.must_contain_any_line() test.must_not_contain_any_line() Update tests to use them. Remove "import string" lines where the change made them unnecessary.
Diffstat (limited to 'test/Configure')
-rw-r--r--test/Configure/clean.py8
-rw-r--r--test/Configure/help.py12
2 files changed, 10 insertions, 10 deletions
diff --git a/test/Configure/clean.py b/test/Configure/clean.py
index a6ba7c10..3fcfcbde 100644
--- a/test/Configure/clean.py
+++ b/test/Configure/clean.py
@@ -66,15 +66,15 @@ lines = [
]
test.run(arguments = '-c clean=0')
-test.must_not_contain_lines(lines, test.stdout())
+test.must_not_contain_any_line(test.stdout(), lines)
test.run(arguments = '-c clean=1')
-test.must_contain_lines(lines, test.stdout())
+test.must_contain_all_lines(test.stdout(), lines)
test.run(arguments = '--clean clean=0')
-test.must_not_contain_lines(lines, test.stdout())
+test.must_not_contain_any_line(test.stdout(), lines)
test.run(arguments = '--clean clean=1')
-test.must_contain_lines(lines, test.stdout())
+test.must_contain_all_lines(test.stdout(), lines)
test.pass_test()
diff --git a/test/Configure/help.py b/test/Configure/help.py
index 32c68eb5..9f585139 100644
--- a/test/Configure/help.py
+++ b/test/Configure/help.py
@@ -68,23 +68,23 @@ lines = [
# The help setting should have no effect on -H, so the -H output
# should never contain the lines.
test.run(arguments = '-H help=0')
-test.must_not_contain_lines(lines, test.stdout())
+test.must_not_contain_any_line(test.stdout(), lines)
test.run(arguments = '-H help=1')
-test.must_not_contain_lines(lines, test.stdout())
+test.must_not_contain_any_line(test.stdout(), lines)
# For -h and --help, the lines appear or not depending on how Configure()
# is initialized.
test.run(arguments = '-h help=0')
-test.must_not_contain_lines(lines, test.stdout())
+test.must_not_contain_any_line(test.stdout(), lines)
test.run(arguments = '-h help=1')
-test.must_contain_lines(lines, test.stdout())
+test.must_contain_all_lines(test.stdout(), lines)
test.run(arguments = '--help help=0')
-test.must_not_contain_lines(lines, test.stdout())
+test.must_not_contain_any_line(test.stdout(), lines)
test.run(arguments = '--help help=1')
-test.must_contain_lines(lines, test.stdout())
+test.must_contain_all_lines(test.stdout(), lines)
test.pass_test()