From 473ef82ef9b3d1f4e2e5adee0fa3fca60cd7755c Mon Sep 17 00:00:00 2001 From: stevenknight Date: Fri, 6 Feb 2009 19:31:50 +0000 Subject: [PATCH] Fixes for use of regular expression with must_contain_all_lines(). git-svn-id: http://scons.tigris.org/svn/scons/trunk@3977 fdb21ef1-2011-0410-befe-b5e4ea1792b1 --- test/scons-time/run/config/subdir.py | 4 +++- test/scons-time/run/option/subdir.py | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/test/scons-time/run/config/subdir.py b/test/scons-time/run/config/subdir.py index 4d213183..b4638680 100644 --- a/test/scons-time/run/config/subdir.py +++ b/test/scons-time/run/config/subdir.py @@ -58,6 +58,8 @@ expect = [ 'SConstruct file directory: .*%ssubdir$' % re.escape(os.sep), ] -test.must_contain_all_lines('foo-000-0.log', content, expect, re.search) +def re_find(content, line): + return re.search(line, content) +test.must_contain_all_lines(content, expect, 'foo-000-0.log', re_find) test.pass_test() diff --git a/test/scons-time/run/option/subdir.py b/test/scons-time/run/option/subdir.py index b96d0e66..eeae750b 100644 --- a/test/scons-time/run/option/subdir.py +++ b/test/scons-time/run/option/subdir.py @@ -54,6 +54,8 @@ expect = [ content = test.read(test.workpath('foo-000-0.log'), mode='r') -test.must_contain_all_lines('foo-000-0.log', content, expect, re.search) +def re_find(content, line): + return re.search(line, content) +test.must_contain_all_lines(content, expect, 'foo-000-0.log', re_find) test.pass_test() -- 2.26.2