1
0
Fork 0
mirror of https://github.com/pry/pry.git synced 2022-11-09 12:35:05 -05:00

add config test for traversal through chain of parents.

This commit is contained in:
Robert Gleeson 2014-01-31 14:12:04 +01:00
parent 0a25818c6b
commit a6783e2628

View file

@ -36,6 +36,14 @@ describe Pry::Config do
local.forget(:shoes)
local.shoes.should == 1
end
it "traverses through a chain of parents" do
root = Pry::Config.from_hash({foo: 21})
local1 = Pry::Config.new(root)
local2 = Pry::Config.new(local1)
local3 = Pry::Config.new(local2)
local3.foo.should == 21
end
end
describe "#[]=" do