blob: 0c11e173acf41e66b7f2c1cfba6fb0b9ce1b51b2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
require File.expand_path('../../../spec_helper', __FILE__)
describe "ENV.replace" do
it "replaces ENV with a Hash" do
ENV["foo"] = "bar"
e = ENV.reject { |k, v| k == "foo" }
e["baz"] = "bam"
ENV.replace e
ENV["foo"].should == nil
ENV["baz"].should == "bam"
ENV.delete "baz"
end
end
|