store-memory 0.0.5 → 0.0.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/store/memory.rb +1 -3
- data/lib/store/memory/version.rb +1 -1
- data/spec/memory_hash_dupper_spec.rb +39 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3d5785233c1081c69b3600b1ebb28aa9859f7455
|
4
|
+
data.tar.gz: a41df1e17471ae45d8aa4416fe0245a173db3c04
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 64cedc573fba7e7a2bb7858e08691278f75a95542c81b48aa6f1286406023678ad2e9982fc7625c0f1903474b05a8884897d11129bb6788167fde397be60be37
|
7
|
+
data.tar.gz: a1fde0a83a4a536fb0aae5649a542b4f274715c51f85a3312af85720dd40b2a57f78e14753bce2d2e21c351dbfc08edeb5641d632b623ac1c68b32b84925ca6a
|
data/lib/store/memory.rb
CHANGED
data/lib/store/memory/version.rb
CHANGED
@@ -38,6 +38,45 @@ describe Store::DataMapper::Memory::HashDupper do
|
|
38
38
|
assert_equal :symbol1, dupped_hash['a']
|
39
39
|
end
|
40
40
|
|
41
|
+
it 'can process fixnum' do
|
42
|
+
hash = {
|
43
|
+
'a' => 32
|
44
|
+
}
|
45
|
+
|
46
|
+
dupped_hash = duplicate(hash)
|
47
|
+
|
48
|
+
assert_equal 32, dupped_hash['a']
|
49
|
+
end
|
50
|
+
|
51
|
+
it 'can process float' do
|
52
|
+
hash = {
|
53
|
+
'a' => 1.3
|
54
|
+
}
|
55
|
+
|
56
|
+
dupped_hash = duplicate(hash)
|
57
|
+
|
58
|
+
assert_equal 1.3, dupped_hash['a']
|
59
|
+
end
|
60
|
+
|
61
|
+
it 'can process true' do
|
62
|
+
hash = {
|
63
|
+
'a' => true
|
64
|
+
}
|
65
|
+
|
66
|
+
dupped_hash = duplicate(hash)
|
67
|
+
|
68
|
+
assert_equal true, dupped_hash['a']
|
69
|
+
end
|
70
|
+
|
71
|
+
it 'can process false' do
|
72
|
+
hash = {
|
73
|
+
'a' => false
|
74
|
+
}
|
75
|
+
|
76
|
+
dupped_hash = duplicate(hash)
|
77
|
+
|
78
|
+
assert_equal false, dupped_hash['a']
|
79
|
+
end
|
41
80
|
|
42
81
|
|
43
82
|
private
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: store-memory
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jan Owiesniak
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-
|
11
|
+
date: 2013-09-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|