cloning an Environment should make a deep copy of its construction variables
This commit is contained in:
1 parent
dc6bac2895
commit
0f5fee359d
2 files changed
+13
-2
No files matched your search
@@ -1,5 +1,16 @@
|
||||
module Rscons
|
||||
describe Environment do
|
||||
describe '.clone' do
|
||||
it 'should create unique copies of each construction variable' do
|
||||
env = Environment.new
|
||||
env["CPPPATH"] << "path1"
|
||||
env2 = env.clone
|
||||
env2["CPPPATH"] << "path2"
|
||||
env["CPPPATH"].should == ["path1"]
|
||||
env2["CPPPATH"].should == ["path1", "path2"]
|
||||
end
|
||||
end
|
||||
|
||||
describe '.parse_makefile_deps' do
|
||||
it 'handles dependencies on one line' do
|
||||
File.should_receive(:read).with('makefile').and_return(<<EOS)
|
||||
|
||||
Reference in new issue
Block a user