Sha256: 6c0ee70e42fb5d7000e849133ff592285705dad277b8d566682271572d3ae323
Contents?: true
Size: 621 Bytes
Versions: 52
Compression:
Stored size: 621 Bytes
Contents
require File.dirname(File.join(__rhoGetCurrentDir(), __FILE__)) + '/../../spec_helper' describe "ENV.update" do it "add the parameter hash to ENV" do ENV["foo"].should == nil ENV.update "foo" => "bar" ENV["foo"].should == "bar" ENV.delete "foo" end it "yields key, the old value and the new value when replacing entries" do ENV.update "foo" => "bar" ENV["foo"].should == "bar" ENV.update("foo" => "boo") do |key, old, new| key.should == "foo" old.should == "bar" new.should == "boo" "rab" end ENV["foo"].should == "rab" ENV.delete "foo" end end
Version data entries
52 entries across 52 versions & 1 rubygems