summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authoredA-qa mort-ora-y <edA-qa@disemia.com>2012-05-06 07:11:11 (GMT)
committeredA-qa mort-ora-y <edA-qa@disemia.com>2012-05-06 07:11:11 (GMT)
commit65986dc7db253685d1e44753a49691b63cf53433 (patch)
tree2406d6521e8bb04188b0efa79d860b291c1f6dae /test
parentb1aa01e14e21176f0dd33919fae528e26280dec4 (diff)
downloadSCons-65986dc7db253685d1e44753a49691b63cf53433.zip
SCons-65986dc7db253685d1e44753a49691b63cf53433.tar.gz
SCons-65986dc7db253685d1e44753a49691b63cf53433.tar.bz2
better fix for issue 2821 -- avoid direct copies of the BuilderDict as it is ambiguous/corrupts the original environment
Diffstat (limited to 'test')
-rw-r--r--test/issue2821.py50
1 files changed, 50 insertions, 0 deletions
diff --git a/test/issue2821.py b/test/issue2821.py
new file mode 100644
index 0000000..b6cda71
--- /dev/null
+++ b/test/issue2821.py
@@ -0,0 +1,50 @@
+#!/usr/bin/env python
+#
+# __COPYRIGHT__
+#
+# Permission is hereby granted, free of charge, to any person obtaining
+# a copy of this software and associated documentation files (the
+# "Software"), to deal in the Software without restriction, including
+# without limitation the rights to use, copy, modify, merge, publish,
+# distribute, sublicense, and/or sell copies of the Software, and to
+# permit persons to whom the Software is furnished to do so, subject to
+# the following conditions:
+#
+# The above copyright notice and this permission notice shall be included
+# in all copies or substantial portions of the Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
+# KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
+# WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+#
+
+__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
+
+import TestSCons
+
+test = TestSCons.TestSCons()
+
+test.write('SConstruct', """
+test = Environment()
+def blub():
+ pass
+
+test.Library.__call__ = blub
+test.Clone()
+assert test.Library.__call__ == blub
+""")
+
+test.run()
+
+test.pass_test()
+
+
+# Local Variables:
+# tab-width:4
+# indent-tabs-mode:nil
+# End:
+# vim: set expandtab tabstop=4 shiftwidth=4: