From: stevenknight Date: Tue, 16 Mar 2004 04:35:44 +0000 (+0000) Subject: Forward the Scanner.Classic name to the underlying base class. X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=0ec8558b6059e2adfb44b55764f85a436aa07b13;p=scons.git Forward the Scanner.Classic name to the underlying base class. git-svn-id: http://scons.tigris.org/svn/scons/trunk@925 fdb21ef1-2011-0410-befe-b5e4ea1792b1 --- diff --git a/src/CHANGES.txt b/src/CHANGES.txt index 20c3b356..a95aab0f 100644 --- a/src/CHANGES.txt +++ b/src/CHANGES.txt @@ -10,6 +10,14 @@ r __COPYRIGHT__ RELEASE 0.96 - XXX + From Chad Austin: + + - Make the CacheDir() directory if it doesn't already exist. + + From Chris Hoeppler: + + - Initialize the name of a Scanner.Classic scanner correctly. + From Steven Knight: - Add an Execute() method for executing actions directly. diff --git a/src/engine/SCons/Scanner/ScannerTests.py b/src/engine/SCons/Scanner/ScannerTests.py index 169c74c8..10515803 100644 --- a/src/engine/SCons/Scanner/ScannerTests.py +++ b/src/engine/SCons/Scanner/ScannerTests.py @@ -233,6 +233,11 @@ class ClassicTestCase(unittest.TestCase): finally: SCons.Node.FS.find_file = save + def test_name(self): + """Test setting the Scanner.Classic name""" + s = SCons.Scanner.Classic("my_name", ['.s'], 'MYPATH', '^my_inc (\S+)') + assert s.name == "my_name", s.name + def test_scan(self): """Test the Scanner.Classic scan() method""" class MyNode: diff --git a/src/engine/SCons/Scanner/__init__.py b/src/engine/SCons/Scanner/__init__.py index dc9abc38..c59480e9 100644 --- a/src/engine/SCons/Scanner/__init__.py +++ b/src/engine/SCons/Scanner/__init__.py @@ -224,6 +224,7 @@ class Classic(Current): kw['path_function'] = FindPathDirs(path_variable, fs) kw['recursive'] = 1 kw['skeys'] = suffixes + kw['name'] = name apply(Current.__init__, (self,) + args, kw)