diff options
author | William Deegan <bill@baddogconsulting.com> | 2017-03-14 03:24:15 (GMT) |
---|---|---|
committer | William Deegan <bill@baddogconsulting.com> | 2017-03-14 03:24:15 (GMT) |
commit | 2da21594f9468283525c27992eb8565d3473841b (patch) | |
tree | 96f6919e6a664a4268777ca6d9b1ebdcf34396da /test/Scanner | |
parent | 496d5d4655ec5eaaf5f47b70a0a5e9f08a310ff3 (diff) | |
download | SCons-2da21594f9468283525c27992eb8565d3473841b.zip SCons-2da21594f9468283525c27992eb8565d3473841b.tar.gz SCons-2da21594f9468283525c27992eb8565d3473841b.tar.bz2 |
py2/3 add mode=r to must_match to fix win32 py27,py3
Diffstat (limited to 'test/Scanner')
-rw-r--r-- | test/Scanner/FindPathDirs.py | 6 | ||||
-rw-r--r-- | test/Scanner/Scanner.py | 32 | ||||
-rw-r--r-- | test/Scanner/generated.py | 2 | ||||
-rw-r--r-- | test/Scanner/no-Dir-node.py | 4 |
4 files changed, 22 insertions, 22 deletions
diff --git a/test/Scanner/FindPathDirs.py b/test/Scanner/FindPathDirs.py index 7f8b993..c56f448 100644 --- a/test/Scanner/FindPathDirs.py +++ b/test/Scanner/FindPathDirs.py @@ -124,7 +124,7 @@ test.write(['inc2', 'yyy'], "inc2/yyy 1\n") test.run() -test.must_match('foo', "foo.k 1 line 1\ninc1/xxx 1\ninc2/yyy 1\nfoo.k 1 line 4\n") +test.must_match('foo', "foo.k 1 line 1\ninc1/xxx 1\ninc2/yyy 1\nfoo.k 1 line 4\n", mode='r') test.up_to_date(arguments = '.') @@ -134,7 +134,7 @@ test.write(['inc1', 'xxx'], "inc1/xxx 2\n") test.run() -test.must_match('foo', "foo.k 1 line 1\ninc1/xxx 2\ninc2/yyy 1\nfoo.k 1 line 4\n") +test.must_match('foo', "foo.k 1 line 1\ninc1/xxx 2\ninc2/yyy 1\nfoo.k 1 line 4\n", mode='r') @@ -142,7 +142,7 @@ test.write(['inc1', 'yyy'], "inc1/yyy 2\n") test.run() -test.must_match('foo', "foo.k 1 line 1\ninc1/xxx 2\ninc1/yyy 2\nfoo.k 1 line 4\n") +test.must_match('foo', "foo.k 1 line 1\ninc1/xxx 2\ninc1/yyy 2\nfoo.k 1 line 4\n", mode='r') diff --git a/test/Scanner/Scanner.py b/test/Scanner/Scanner.py index 625b372..d5e5c3a 100644 --- a/test/Scanner/Scanner.py +++ b/test/Scanner/Scanner.py @@ -180,10 +180,10 @@ blork(["moo.ork"], ["moo.blork"]) test.run(arguments = '.', stdout=expect) -test.must_match('foo', "foo.k 1 line 1\nxxx 1\nyyy 1\nfoo.k 1 line 4\n") -test.must_match('bar', "yyy 1\nbar.in 1 line 2\nbar.in 1 line 3\nzzz 1\n") -test.must_match('junk', "yyy 1\njunk.k2 1 line 2\njunk.k2 1 line 3\nzzz 1\n") -test.must_match('moo.ork', "xxx 1\nmoo.lork 1 line 2\nyyy 1\nmoo.lork 1 line 4\ninclude zzz\n") +test.must_match('foo', "foo.k 1 line 1\nxxx 1\nyyy 1\nfoo.k 1 line 4\n", mode='r') +test.must_match('bar', "yyy 1\nbar.in 1 line 2\nbar.in 1 line 3\nzzz 1\n", mode='r') +test.must_match('junk', "yyy 1\njunk.k2 1 line 2\njunk.k2 1 line 3\nzzz 1\n", mode='r') +test.must_match('moo.ork', "xxx 1\nmoo.lork 1 line 2\nyyy 1\nmoo.lork 1 line 4\ninclude zzz\n", mode='r') test.up_to_date(arguments = '.') @@ -197,10 +197,10 @@ blork(["moo.ork"], ["moo.blork"]) test.run(arguments = '.', stdout=expect) -test.must_match('foo', "foo.k 1 line 1\nxxx 2\nyyy 1\nfoo.k 1 line 4\n") -test.must_match('bar', "yyy 1\nbar.in 1 line 2\nbar.in 1 line 3\nzzz 1\n") -test.must_match('junk', "yyy 1\njunk.k2 1 line 2\njunk.k2 1 line 3\nzzz 1\n") -test.must_match('moo.ork', "xxx 2\nmoo.lork 1 line 2\nyyy 1\nmoo.lork 1 line 4\ninclude zzz\n") +test.must_match('foo', "foo.k 1 line 1\nxxx 2\nyyy 1\nfoo.k 1 line 4\n", mode='r') +test.must_match('bar', "yyy 1\nbar.in 1 line 2\nbar.in 1 line 3\nzzz 1\n", mode='r') +test.must_match('junk', "yyy 1\njunk.k2 1 line 2\njunk.k2 1 line 3\nzzz 1\n", mode='r') +test.must_match('moo.ork', "xxx 2\nmoo.lork 1 line 2\nyyy 1\nmoo.lork 1 line 4\ninclude zzz\n", mode='r') test.write('yyy', "yyy 2\n") @@ -214,10 +214,10 @@ blork(["moo.ork"], ["moo.blork"]) test.run(arguments = '.', stdout=expect) -test.must_match('foo', "foo.k 1 line 1\nxxx 2\nyyy 2\nfoo.k 1 line 4\n") -test.must_match('bar', "yyy 2\nbar.in 1 line 2\nbar.in 1 line 3\nzzz 1\n") -test.must_match('junk', "yyy 2\njunk.k2 1 line 2\njunk.k2 1 line 3\nzzz 1\n") -test.must_match('moo.ork', "xxx 2\nmoo.lork 1 line 2\nyyy 2\nmoo.lork 1 line 4\ninclude zzz\n") +test.must_match('foo', "foo.k 1 line 1\nxxx 2\nyyy 2\nfoo.k 1 line 4\n", mode='r') +test.must_match('bar', "yyy 2\nbar.in 1 line 2\nbar.in 1 line 3\nzzz 1\n", mode='r') +test.must_match('junk', "yyy 2\njunk.k2 1 line 2\njunk.k2 1 line 3\nzzz 1\n", mode='r') +test.must_match('moo.ork', "xxx 2\nmoo.lork 1 line 2\nyyy 2\nmoo.lork 1 line 4\ninclude zzz\n", mode='r') test.write('zzz', "zzz 2\n") @@ -228,10 +228,10 @@ expect = test.wrap_stdout("""\ test.run(arguments = '.', stdout=expect) -test.must_match('foo', "foo.k 1 line 1\nxxx 2\nyyy 2\nfoo.k 1 line 4\n") -test.must_match('bar', "yyy 2\nbar.in 1 line 2\nbar.in 1 line 3\nzzz 2\n") -test.must_match('junk', "yyy 2\njunk.k2 1 line 2\njunk.k2 1 line 3\nzzz 2\n") -test.must_match('moo.ork', "xxx 2\nmoo.lork 1 line 2\nyyy 2\nmoo.lork 1 line 4\ninclude zzz\n") +test.must_match('foo', "foo.k 1 line 1\nxxx 2\nyyy 2\nfoo.k 1 line 4\n", mode='r') +test.must_match('bar', "yyy 2\nbar.in 1 line 2\nbar.in 1 line 3\nzzz 2\n", mode='r') +test.must_match('junk', "yyy 2\njunk.k2 1 line 2\njunk.k2 1 line 3\nzzz 2\n", mode='r') +test.must_match('moo.ork', "xxx 2\nmoo.lork 1 line 2\nyyy 2\nmoo.lork 1 line 4\ninclude zzz\n", mode='r') test.up_to_date(arguments = 'foo') diff --git a/test/Scanner/generated.py b/test/Scanner/generated.py index 9dd2a86..4a368b4 100644 --- a/test/Scanner/generated.py +++ b/test/Scanner/generated.py @@ -431,7 +431,7 @@ libg_gx.h: 2 libg_gy.h: 1 libg_gz.h: 1 libg_w.h: 2 -""") +""", mode='r') test.pass_test() diff --git a/test/Scanner/no-Dir-node.py b/test/Scanner/no-Dir-node.py index 123764e..69b665a 100644 --- a/test/Scanner/no-Dir-node.py +++ b/test/Scanner/no-Dir-node.py @@ -122,13 +122,13 @@ test.must_match('subdir/foo', """\ subdir/foo.k inc1/include.h inc2/include.h -""") +""", mode='r') test.must_match('list.out', """\ %(subdir_SConscript)s %(subdir_foo)s %(subdir_foo_k)s -""" % locals()) +""" % locals(), mode='r') test.pass_test() |