spec/lazier/hash_spec.rb in lazier-3.5.7 vs spec/lazier/hash_spec.rb in lazier-4.0.0
- old
+ new
@@ -1,6 +1,5 @@
-# encoding: utf-8
#
# This file is part of the lazier gem. Copyright (C) 2013 and above Shogun <shogun@cowtech.it>.
# Licensed under the MIT license, which can be found at http://www.opensource.org/licenses/mit-license.php.
#
@@ -13,29 +12,9 @@
rv
}
before(:each) do
::Lazier.load!
- end
-
- describe "method access" do
- it "it is not enabled by default" do
- expect { subject.b }.to raise_error(NoMethodError)
- end
- end
-
- describe "allows access to keys using dotted notation" do
- before(:each) do
- ::Lazier.load!(:hash_method_access)
- end
-
- it "should allow method subject for symbol key" do
- subject.b.f = 4
-
- expect(subject.a).to eq(1)
- expect(subject.b.c).to eq(2)
- expect(subject["b"]["f"]).to eq(4)
- end
end
describe "#compact" do
it "should remove blank keys" do
expect({a: 1, b: nil}.compact).to eq({a: 1})
\ No newline at end of file