summaryrefslogtreecommitdiff
path: root/test/DVIPS
diff options
context:
space:
mode:
authorSteven Knight <knight@baldmt.com>2008-10-08 00:58:12 +0000
committerSteven Knight <knight@baldmt.com>2008-10-08 00:58:12 +0000
commit7b5b6bbc0f83eb8e22e7a9325944bf0680c847ed (patch)
tree803afe9991218fcde7c656d868a4d1c198ba8bd3 /test/DVIPS
parent74dada7aff0f470de7f5cb2ddf4a78550a60da62 (diff)
downloadscons-7b5b6bbc0f83eb8e22e7a9325944bf0680c847ed.tar.gz
Update test scripts with more information must_*() methods.
Diffstat (limited to 'test/DVIPS')
-rw-r--r--test/DVIPS/DVIPS.py23
-rw-r--r--test/DVIPS/DVIPSFLAGS.py23
2 files changed, 22 insertions, 24 deletions
diff --git a/test/DVIPS/DVIPS.py b/test/DVIPS/DVIPS.py
index 882cb6a2..b50b3cbb 100644
--- a/test/DVIPS/DVIPS.py
+++ b/test/DVIPS/DVIPS.py
@@ -25,9 +25,8 @@
__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
import os
-import os.path
import string
-import sys
+
import TestSCons
_python_ = TestSCons._python_
@@ -109,13 +108,13 @@ test.write('test4.latex', r"""This is a .latex test.
test.run(arguments = '.', stderr = None)
-test.fail_test(test.read('test1.ps') != "This is a .dvi test.\n")
+test.must_match('test1.ps', "This is a .dvi test.\n")
-test.fail_test(test.read('test2.ps') != "This is a .tex test.\n")
+test.must_match('test2.ps', "This is a .tex test.\n")
-test.fail_test(test.read('test3.ps') != "This is a .ltx test.\n")
+test.must_match('test3.ps', "This is a .ltx test.\n")
-test.fail_test(test.read('test4.ps') != "This is a .latex test.\n")
+test.must_match('test4.ps', "This is a .latex test.\n")
@@ -162,9 +161,9 @@ This is the %s LaTeX file.
test.run(arguments = 'foo.dvi', stderr = None)
- test.fail_test(os.path.exists(test.workpath('wrapper.out')))
+ test.must_not_exist(test.workpath('wrapper.out'))
- test.fail_test(not os.path.exists(test.workpath('foo.dvi')))
+ test.must_exist(test.workpath('foo.dvi'))
test.run(arguments = 'bar1.ps bar2.ps bar3.ps', stderr = None)
@@ -173,10 +172,10 @@ dvips -o bar2.ps bar2.dvi
dvips -o bar3.ps bar3.dvi
"""
- test.fail_test(test.read('wrapper.out') != expect)
+ test.must_match('wrapper.out', expect)
- test.fail_test(not os.path.exists(test.workpath('bar1.ps')))
- test.fail_test(not os.path.exists(test.workpath('bar2.ps')))
- test.fail_test(not os.path.exists(test.workpath('bar3.ps')))
+ test.must_exist(test.workpath('bar1.ps'))
+ test.must_exist(test.workpath('bar2.ps'))
+ test.must_exist(test.workpath('bar3.ps'))
test.pass_test()
diff --git a/test/DVIPS/DVIPSFLAGS.py b/test/DVIPS/DVIPSFLAGS.py
index 4b70e412..9fac804c 100644
--- a/test/DVIPS/DVIPSFLAGS.py
+++ b/test/DVIPS/DVIPSFLAGS.py
@@ -25,9 +25,8 @@
__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
import os
-import os.path
import string
-import sys
+
import TestSCons
_python_ = TestSCons._python_
@@ -116,13 +115,13 @@ test.write('test4.latex', r"""This is a .latex test.
test.run(arguments = '.', stderr = None)
-test.fail_test(test.read('test1.ps') != " -x\nThis is a .dvi test.\n")
+test.must_match('test1.ps', " -x\nThis is a .dvi test.\n")
-test.fail_test(test.read('test2.ps') != " -x\nThis is a .tex test.\n")
+test.must_match('test2.ps', " -x\nThis is a .tex test.\n")
-test.fail_test(test.read('test3.ps') != " -x\nThis is a .ltx test.\n")
+test.must_match('test3.ps', " -x\nThis is a .ltx test.\n")
-test.fail_test(test.read('test4.ps') != " -x\nThis is a .latex test.\n")
+test.must_match('test4.ps', " -x\nThis is a .latex test.\n")
@@ -169,9 +168,9 @@ This is the %s LaTeX file.
test.run(arguments = 'foo.dvi', stderr = None)
- test.fail_test(os.path.exists(test.workpath('wrapper.out')))
+ test.must_not_exist(test.workpath('wrapper.out'))
- test.fail_test(not os.path.exists(test.workpath('foo.dvi')))
+ test.must_exist(test.workpath('foo.dvi'))
test.run(arguments = 'bar1.ps bar2.ps bar3.ps', stderr = None)
@@ -180,10 +179,10 @@ dvips -o bar2.ps bar2.dvi
dvips -o bar3.ps bar3.dvi
"""
- test.fail_test(test.read('wrapper.out') != expect)
+ test.must_match('wrapper.out', expect)
- test.fail_test(not os.path.exists(test.workpath('bar1.ps')))
- test.fail_test(not os.path.exists(test.workpath('bar2.ps')))
- test.fail_test(not os.path.exists(test.workpath('bar3.ps')))
+ test.must_exist(test.workpath('bar1.ps'))
+ test.must_exist(test.workpath('bar2.ps'))
+ test.must_exist(test.workpath('bar3.ps'))
test.pass_test()