chozo 0.0.2 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/chozo/core_ext/hash.rb +1 -1
- data/lib/chozo/version.rb +1 -1
- data/spec/unit/chozo/core_ext/hash_spec.rb +16 -0
- metadata +3 -3
data/lib/chozo/core_ext/hash.rb
CHANGED
data/lib/chozo/version.rb
CHANGED
@@ -57,5 +57,21 @@ describe Hash do
|
|
57
57
|
subject.dig("nothing.is.here").should be_nil
|
58
58
|
end
|
59
59
|
end
|
60
|
+
|
61
|
+
context "when the Hash contains symbols for keys" do
|
62
|
+
subject do
|
63
|
+
{
|
64
|
+
we: {
|
65
|
+
found: {
|
66
|
+
something: :symbol_value
|
67
|
+
}
|
68
|
+
}
|
69
|
+
}
|
70
|
+
end
|
71
|
+
|
72
|
+
it "returns the value at the dotted path" do
|
73
|
+
subject.dig("we.found.something").should eql(:symbol_value)
|
74
|
+
end
|
75
|
+
end
|
60
76
|
end
|
61
77
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: chozo
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-10-
|
12
|
+
date: 2012-10-11 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activesupport
|
@@ -315,7 +315,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
315
315
|
version: '0'
|
316
316
|
segments:
|
317
317
|
- 0
|
318
|
-
hash: -
|
318
|
+
hash: -1213851817618954320
|
319
319
|
requirements: []
|
320
320
|
rubyforge_project:
|
321
321
|
rubygems_version: 1.8.23
|