diff options
author | Steven Knight <knight@baldmt.com> | 2009-01-13 10:32:30 (GMT) |
---|---|---|
committer | Steven Knight <knight@baldmt.com> | 2009-01-13 10:32:30 (GMT) |
commit | fdfc390f2a04e064e24b016d50a69c058ee20d96 (patch) | |
tree | 88d9372bef4318ae77b9c0335610fe4770e6ecca /src/engine | |
parent | 16aeca0502a1bbeac495df27220d52b4f381ab2c (diff) | |
download | SCons-fdfc390f2a04e064e24b016d50a69c058ee20d96.zip SCons-fdfc390f2a04e064e24b016d50a69c058ee20d96.tar.gz SCons-fdfc390f2a04e064e24b016d50a69c058ee20d96.tar.bz2 |
Fix ability to Install() the same file multiple times.
Diffstat (limited to 'src/engine')
-rw-r--r-- | src/engine/SCons/Executor.py | 2 | ||||
-rw-r--r-- | src/engine/SCons/ExecutorTests.py | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/engine/SCons/Executor.py b/src/engine/SCons/Executor.py index 7e831e3..7d331c1 100644 --- a/src/engine/SCons/Executor.py +++ b/src/engine/SCons/Executor.py @@ -372,7 +372,7 @@ class Executor: # TODO(batch): extend to multiple batches assert (len(self.batches) == 1) # TODO(batch): remove duplicates? - #slist = filter(lambda x, s=self.batches[0].sources: x not in s, sources) + sources = filter(lambda x, s=self.batches[0].sources: x not in s, sources) self.batches[0].sources.extend(sources) def get_sources(self): diff --git a/src/engine/SCons/ExecutorTests.py b/src/engine/SCons/ExecutorTests.py index 79e9d03..37c253d 100644 --- a/src/engine/SCons/ExecutorTests.py +++ b/src/engine/SCons/ExecutorTests.py @@ -275,11 +275,11 @@ class ExecutorTestCase(unittest.TestCase): x.add_sources(['s1', 's2']) sources = x.get_all_sources() - assert sources == ['s1', 's2', 's1', 's2'], sources + assert sources == ['s1', 's2'], sources x.add_sources(['s3', 's1', 's4']) sources = x.get_all_sources() - assert sources == ['s1', 's2', 's1', 's2', 's3', 's1', 's4'], sources + assert sources == ['s1', 's2', 's3', 's4'], sources def test_get_sources(self): """Test getting sources from an Executor""" @@ -289,11 +289,11 @@ class ExecutorTestCase(unittest.TestCase): x.add_sources(['s1', 's2']) sources = x.get_sources() - assert sources == ['s1', 's2', 's1', 's2'], sources + assert sources == ['s1', 's2'], sources x.add_sources(['s3', 's1', 's4']) sources = x.get_sources() - assert sources == ['s1', 's2', 's1', 's2', 's3', 's1', 's4'], sources + assert sources == ['s1', 's2', 's3', 's4'], sources def test_prepare(self): """Test the Executor's prepare() method""" |