moneta 0.7.4 → 0.7.5
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/.gitignore +1 -2
- data/.travis.yml +20 -13
- data/CHANGES +5 -0
- data/Gemfile +24 -25
- data/LICENSE +1 -1
- data/README.md +32 -16
- data/Rakefile +36 -6
- data/lib/moneta/builder.rb +20 -6
- data/lib/moneta/mixins.rb +11 -4
- data/lib/moneta/version.rb +1 -1
- data/script/benchmarks +378 -0
- data/script/{generate-specs.rb → generate-specs} +92 -83
- data/script/install-bundle +26 -0
- data/script/kill-travis +16 -0
- data/script/start-services +8 -0
- data/script/upload-bundle +2 -0
- data/spec/helper.rb +9 -3
- data/spec/moneta/adapter_activerecord_spec.rb +1 -1
- data/spec/moneta/adapter_cassandra_spec.rb +1 -1
- data/spec/moneta/adapter_cassandra_with_default_expires_spec.rb +2 -2
- data/spec/moneta/adapter_client_spec.rb +1 -1
- data/spec/moneta/adapter_cookie_spec.rb +2 -2
- data/spec/moneta/adapter_couch_spec.rb +1 -1
- data/spec/moneta/adapter_datamapper_spec.rb +1 -1
- data/spec/moneta/adapter_daybreak_spec.rb +2 -2
- data/spec/moneta/adapter_dbm_spec.rb +1 -1
- data/spec/moneta/adapter_file_spec.rb +1 -1
- data/spec/moneta/adapter_fog_spec.rb +2 -2
- data/spec/moneta/adapter_gdbm_spec.rb +1 -1
- data/spec/moneta/adapter_hbase_spec.rb +1 -1
- data/spec/moneta/adapter_leveldb_spec.rb +1 -1
- data/spec/moneta/adapter_localmemcache_spec.rb +1 -1
- data/spec/moneta/adapter_lruhash_spec.rb +2 -2
- data/spec/moneta/adapter_memcached_dalli_spec.rb +1 -1
- data/spec/moneta/adapter_memcached_dalli_with_default_expires_spec.rb +1 -1
- data/spec/moneta/adapter_memcached_native_spec.rb +1 -1
- data/spec/moneta/adapter_memcached_native_with_default_expires_spec.rb +1 -1
- data/spec/moneta/adapter_memcached_spec.rb +1 -1
- data/spec/moneta/adapter_memcached_with_default_expires_spec.rb +1 -1
- data/spec/moneta/adapter_memory_spec.rb +19 -1
- data/spec/moneta/adapter_mongo_spec.rb +2 -2
- data/spec/moneta/adapter_mongo_with_default_expires_spec.rb +1 -1
- data/spec/moneta/adapter_pstore_spec.rb +1 -1
- data/spec/moneta/adapter_redis_spec.rb +1 -1
- data/spec/moneta/adapter_redis_with_default_expires_spec.rb +1 -1
- data/spec/moneta/adapter_restclient_spec.rb +1 -1
- data/spec/moneta/adapter_riak_spec.rb +1 -1
- data/spec/moneta/adapter_sdbm_spec.rb +1 -1
- data/spec/moneta/adapter_sequel_spec.rb +1 -1
- data/spec/moneta/adapter_sqlite_spec.rb +1 -1
- data/spec/moneta/adapter_tdb_spec.rb +1 -1
- data/spec/moneta/adapter_tokyocabinet_bdb_spec.rb +1 -1
- data/spec/moneta/adapter_tokyocabinet_hdb_spec.rb +1 -1
- data/spec/moneta/adapter_yaml_spec.rb +1 -1
- data/spec/moneta/cache_file_memory_spec.rb +2 -2
- data/spec/moneta/cache_memory_null_spec.rb +2 -2
- data/spec/moneta/expires_file_spec.rb +1 -1
- data/spec/moneta/expires_memory_spec.rb +19 -19
- data/spec/moneta/expires_memory_with_default_expires_spec.rb +19 -19
- data/spec/moneta/lock_spec.rb +19 -1
- data/spec/moneta/null_adapter_spec.rb +1 -1
- data/spec/moneta/optionmerger_spec.rb +14 -1
- data/spec/moneta/pool_spec.rb +1 -1
- data/spec/moneta/proxy_expires_memory_spec.rb +19 -1
- data/spec/moneta/proxy_redis_spec.rb +1 -1
- data/spec/moneta/shared_spec.rb +3 -3
- data/spec/moneta/simple_activerecord_spec.rb +1 -1
- data/spec/moneta/simple_activerecord_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_cassandra_spec.rb +1 -1
- data/spec/moneta/simple_client_tcp_spec.rb +1 -1
- data/spec/moneta/simple_client_unix_spec.rb +1 -1
- data/spec/moneta/simple_couch_spec.rb +1 -1
- data/spec/moneta/simple_couch_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_datamapper_spec.rb +1 -1
- data/spec/moneta/simple_datamapper_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_datamapper_with_repository_spec.rb +1 -1
- data/spec/moneta/simple_daybreak_spec.rb +1 -1
- data/spec/moneta/simple_daybreak_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_dbm_spec.rb +1 -1
- data/spec/moneta/simple_dbm_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_file_spec.rb +1 -1
- data/spec/moneta/simple_file_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_fog_spec.rb +1 -1
- data/spec/moneta/simple_fog_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_gdbm_spec.rb +1 -1
- data/spec/moneta/simple_gdbm_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_hashfile_spec.rb +1 -1
- data/spec/moneta/simple_hashfile_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_hbase_spec.rb +1 -1
- data/spec/moneta/simple_hbase_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_leveldb_spec.rb +1 -1
- data/spec/moneta/simple_leveldb_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_localmemcache_spec.rb +1 -1
- data/spec/moneta/simple_localmemcache_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_lruhash_spec.rb +1 -1
- data/spec/moneta/simple_lruhash_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_memcached_dalli_spec.rb +1 -1
- data/spec/moneta/simple_memcached_native_spec.rb +1 -1
- data/spec/moneta/simple_memcached_spec.rb +1 -1
- data/spec/moneta/simple_memory_spec.rb +1 -1
- data/spec/moneta/simple_memory_with_compress_spec.rb +1 -1
- data/spec/moneta/simple_memory_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_memory_with_json_key_serializer_spec.rb +1 -1
- data/spec/moneta/simple_memory_with_json_serializer_spec.rb +1 -1
- data/spec/moneta/simple_memory_with_json_value_serializer_spec.rb +1 -1
- data/spec/moneta/simple_memory_with_prefix_spec.rb +1 -1
- data/spec/moneta/simple_memory_with_snappy_compress_spec.rb +1 -1
- data/spec/moneta/simple_mongo_spec.rb +1 -1
- data/spec/moneta/simple_null_spec.rb +1 -1
- data/spec/moneta/simple_pstore_spec.rb +1 -1
- data/spec/moneta/simple_pstore_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_redis_spec.rb +1 -1
- data/spec/moneta/simple_restclient_spec.rb +1 -1
- data/spec/moneta/simple_riak_spec.rb +1 -1
- data/spec/moneta/simple_riak_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_sdbm_spec.rb +1 -1
- data/spec/moneta/simple_sdbm_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_sequel_spec.rb +1 -1
- data/spec/moneta/simple_sequel_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_sqlite_spec.rb +1 -1
- data/spec/moneta/simple_sqlite_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_tdb_spec.rb +1 -1
- data/spec/moneta/simple_tdb_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_tokyocabinet_spec.rb +1 -1
- data/spec/moneta/simple_tokyocabinet_with_expires_spec.rb +1 -1
- data/spec/moneta/simple_yaml_spec.rb +1 -1
- data/spec/moneta/simple_yaml_with_expires_spec.rb +1 -1
- data/spec/moneta/stack_file_memory_spec.rb +2 -2
- data/spec/moneta/stack_memory_file_spec.rb +3 -3
- data/spec/moneta/transformer_bencode_spec.rb +1 -1
- data/spec/moneta/transformer_bert_spec.rb +1 -1
- data/spec/moneta/transformer_bson_spec.rb +1 -1
- data/spec/moneta/transformer_bzip2_spec.rb +1 -1
- data/spec/moneta/transformer_json_spec.rb +1 -1
- data/spec/moneta/transformer_key_marshal_spec.rb +19 -19
- data/spec/moneta/transformer_key_yaml_spec.rb +19 -19
- data/spec/moneta/transformer_lzma_spec.rb +1 -1
- data/spec/moneta/transformer_lzo_spec.rb +1 -1
- data/spec/moneta/transformer_marshal_base64_spec.rb +1 -1
- data/spec/moneta/transformer_marshal_escape_spec.rb +1 -1
- data/spec/moneta/transformer_marshal_hmac_spec.rb +1 -1
- data/spec/moneta/transformer_marshal_md5_spec.rb +1 -1
- data/spec/moneta/transformer_marshal_md5_spread_spec.rb +1 -1
- data/spec/moneta/transformer_marshal_prefix_spec.rb +1 -1
- data/spec/moneta/transformer_marshal_rmd160_spec.rb +1 -1
- data/spec/moneta/transformer_marshal_sha1_spec.rb +1 -1
- data/spec/moneta/transformer_marshal_sha256_spec.rb +1 -1
- data/spec/moneta/transformer_marshal_sha384_spec.rb +1 -1
- data/spec/moneta/transformer_marshal_sha512_spec.rb +1 -1
- data/spec/moneta/transformer_marshal_spec.rb +1 -1
- data/spec/moneta/transformer_marshal_truncate_spec.rb +1 -1
- data/spec/moneta/transformer_marshal_uuencode_spec.rb +1 -1
- data/spec/moneta/transformer_msgpack_spec.rb +1 -1
- data/spec/moneta/transformer_ox_spec.rb +1 -1
- data/spec/moneta/transformer_quicklz_spec.rb +1 -1
- data/spec/moneta/transformer_snappy_spec.rb +1 -1
- data/spec/moneta/transformer_tnet_spec.rb +1 -1
- data/spec/moneta/transformer_value_marshal_spec.rb +1 -1
- data/spec/moneta/transformer_value_yaml_spec.rb +1 -1
- data/spec/moneta/transformer_yaml_spec.rb +1 -1
- data/spec/moneta/transformer_zlib_spec.rb +1 -1
- data/spec/monetaspecs.rb +655 -151
- metadata +8 -6
- data/benchmarks/run.rb +0 -327
- data/script/install-bundle.rb +0 -35
data/spec/monetaspecs.rb
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Generated by generate-specs
|
|
1
|
+
# Generated by generate-specs
|
|
2
2
|
|
|
3
3
|
#################### null_nilkey_nilvalue ####################
|
|
4
4
|
|
|
@@ -1721,26 +1721,54 @@ end
|
|
|
1721
1721
|
shared_examples_for 'returndifferent_nilkey_stringvalue' do
|
|
1722
1722
|
it 'guarantees that a different value is retrieved' do
|
|
1723
1723
|
value = "strval1"
|
|
1724
|
-
store[0] =
|
|
1725
|
-
store[0].should_not be_equal(
|
|
1724
|
+
store[0] = value
|
|
1725
|
+
store[0].should_not be_equal(value)
|
|
1726
1726
|
end
|
|
1727
1727
|
|
|
1728
1728
|
it 'guarantees that a different value is retrieved' do
|
|
1729
1729
|
value = "strval1"
|
|
1730
|
-
store[nil] =
|
|
1731
|
-
store[nil].should_not be_equal(
|
|
1730
|
+
store[nil] = value
|
|
1731
|
+
store[nil].should_not be_equal(value)
|
|
1732
1732
|
end
|
|
1733
1733
|
|
|
1734
1734
|
it 'guarantees that a different value is retrieved' do
|
|
1735
1735
|
value = "strval2"
|
|
1736
|
-
store[0] =
|
|
1737
|
-
store[0].should_not be_equal(
|
|
1736
|
+
store[0] = value
|
|
1737
|
+
store[0].should_not be_equal(value)
|
|
1738
1738
|
end
|
|
1739
1739
|
|
|
1740
1740
|
it 'guarantees that a different value is retrieved' do
|
|
1741
1741
|
value = "strval2"
|
|
1742
|
-
store[nil] =
|
|
1743
|
-
store[nil].should_not be_equal(
|
|
1742
|
+
store[nil] = value
|
|
1743
|
+
store[nil].should_not be_equal(value)
|
|
1744
|
+
end
|
|
1745
|
+
end
|
|
1746
|
+
|
|
1747
|
+
#################### returnsame_nilkey_stringvalue ####################
|
|
1748
|
+
|
|
1749
|
+
shared_examples_for 'returnsame_nilkey_stringvalue' do
|
|
1750
|
+
it 'guarantees that the same value is retrieved' do
|
|
1751
|
+
value = "strval1"
|
|
1752
|
+
store[0] = value
|
|
1753
|
+
store[0].should be_equal(value)
|
|
1754
|
+
end
|
|
1755
|
+
|
|
1756
|
+
it 'guarantees that the same value is retrieved' do
|
|
1757
|
+
value = "strval1"
|
|
1758
|
+
store[nil] = value
|
|
1759
|
+
store[nil].should be_equal(value)
|
|
1760
|
+
end
|
|
1761
|
+
|
|
1762
|
+
it 'guarantees that the same value is retrieved' do
|
|
1763
|
+
value = "strval2"
|
|
1764
|
+
store[0] = value
|
|
1765
|
+
store[0].should be_equal(value)
|
|
1766
|
+
end
|
|
1767
|
+
|
|
1768
|
+
it 'guarantees that the same value is retrieved' do
|
|
1769
|
+
value = "strval2"
|
|
1770
|
+
store[nil] = value
|
|
1771
|
+
store[nil].should be_equal(value)
|
|
1744
1772
|
end
|
|
1745
1773
|
end
|
|
1746
1774
|
|
|
@@ -2197,26 +2225,54 @@ end
|
|
|
2197
2225
|
shared_examples_for 'returndifferent_nilkey_hashvalue' do
|
|
2198
2226
|
it 'guarantees that a different value is retrieved' do
|
|
2199
2227
|
value = {"hashval1"=>["array1", 1]}
|
|
2200
|
-
store[0] =
|
|
2201
|
-
store[0].should_not be_equal(
|
|
2228
|
+
store[0] = value
|
|
2229
|
+
store[0].should_not be_equal(value)
|
|
2202
2230
|
end
|
|
2203
2231
|
|
|
2204
2232
|
it 'guarantees that a different value is retrieved' do
|
|
2205
2233
|
value = {"hashval1"=>["array1", 1]}
|
|
2206
|
-
store[nil] =
|
|
2207
|
-
store[nil].should_not be_equal(
|
|
2234
|
+
store[nil] = value
|
|
2235
|
+
store[nil].should_not be_equal(value)
|
|
2208
2236
|
end
|
|
2209
2237
|
|
|
2210
2238
|
it 'guarantees that a different value is retrieved' do
|
|
2211
2239
|
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
2212
|
-
store[0] =
|
|
2213
|
-
store[0].should_not be_equal(
|
|
2240
|
+
store[0] = value
|
|
2241
|
+
store[0].should_not be_equal(value)
|
|
2214
2242
|
end
|
|
2215
2243
|
|
|
2216
2244
|
it 'guarantees that a different value is retrieved' do
|
|
2217
2245
|
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
2218
|
-
store[nil] =
|
|
2219
|
-
store[nil].should_not be_equal(
|
|
2246
|
+
store[nil] = value
|
|
2247
|
+
store[nil].should_not be_equal(value)
|
|
2248
|
+
end
|
|
2249
|
+
end
|
|
2250
|
+
|
|
2251
|
+
#################### returnsame_nilkey_hashvalue ####################
|
|
2252
|
+
|
|
2253
|
+
shared_examples_for 'returnsame_nilkey_hashvalue' do
|
|
2254
|
+
it 'guarantees that the same value is retrieved' do
|
|
2255
|
+
value = {"hashval1"=>["array1", 1]}
|
|
2256
|
+
store[0] = value
|
|
2257
|
+
store[0].should be_equal(value)
|
|
2258
|
+
end
|
|
2259
|
+
|
|
2260
|
+
it 'guarantees that the same value is retrieved' do
|
|
2261
|
+
value = {"hashval1"=>["array1", 1]}
|
|
2262
|
+
store[nil] = value
|
|
2263
|
+
store[nil].should be_equal(value)
|
|
2264
|
+
end
|
|
2265
|
+
|
|
2266
|
+
it 'guarantees that the same value is retrieved' do
|
|
2267
|
+
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
2268
|
+
store[0] = value
|
|
2269
|
+
store[0].should be_equal(value)
|
|
2270
|
+
end
|
|
2271
|
+
|
|
2272
|
+
it 'guarantees that the same value is retrieved' do
|
|
2273
|
+
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
2274
|
+
store[nil] = value
|
|
2275
|
+
store[nil].should be_equal(value)
|
|
2220
2276
|
end
|
|
2221
2277
|
end
|
|
2222
2278
|
|
|
@@ -2673,26 +2729,54 @@ end
|
|
|
2673
2729
|
shared_examples_for 'returndifferent_nilkey_objectvalue' do
|
|
2674
2730
|
it 'guarantees that a different value is retrieved' do
|
|
2675
2731
|
value = Value.new(:objval1)
|
|
2676
|
-
store[0] =
|
|
2677
|
-
store[0].should_not be_equal(
|
|
2732
|
+
store[0] = value
|
|
2733
|
+
store[0].should_not be_equal(value)
|
|
2678
2734
|
end
|
|
2679
2735
|
|
|
2680
2736
|
it 'guarantees that a different value is retrieved' do
|
|
2681
2737
|
value = Value.new(:objval1)
|
|
2682
|
-
store[nil] =
|
|
2683
|
-
store[nil].should_not be_equal(
|
|
2738
|
+
store[nil] = value
|
|
2739
|
+
store[nil].should_not be_equal(value)
|
|
2684
2740
|
end
|
|
2685
2741
|
|
|
2686
2742
|
it 'guarantees that a different value is retrieved' do
|
|
2687
2743
|
value = Value.new(:objval2)
|
|
2688
|
-
store[0] =
|
|
2689
|
-
store[0].should_not be_equal(
|
|
2744
|
+
store[0] = value
|
|
2745
|
+
store[0].should_not be_equal(value)
|
|
2690
2746
|
end
|
|
2691
2747
|
|
|
2692
2748
|
it 'guarantees that a different value is retrieved' do
|
|
2693
2749
|
value = Value.new(:objval2)
|
|
2694
|
-
store[nil] =
|
|
2695
|
-
store[nil].should_not be_equal(
|
|
2750
|
+
store[nil] = value
|
|
2751
|
+
store[nil].should_not be_equal(value)
|
|
2752
|
+
end
|
|
2753
|
+
end
|
|
2754
|
+
|
|
2755
|
+
#################### returnsame_nilkey_objectvalue ####################
|
|
2756
|
+
|
|
2757
|
+
shared_examples_for 'returnsame_nilkey_objectvalue' do
|
|
2758
|
+
it 'guarantees that the same value is retrieved' do
|
|
2759
|
+
value = Value.new(:objval1)
|
|
2760
|
+
store[0] = value
|
|
2761
|
+
store[0].should be_equal(value)
|
|
2762
|
+
end
|
|
2763
|
+
|
|
2764
|
+
it 'guarantees that the same value is retrieved' do
|
|
2765
|
+
value = Value.new(:objval1)
|
|
2766
|
+
store[nil] = value
|
|
2767
|
+
store[nil].should be_equal(value)
|
|
2768
|
+
end
|
|
2769
|
+
|
|
2770
|
+
it 'guarantees that the same value is retrieved' do
|
|
2771
|
+
value = Value.new(:objval2)
|
|
2772
|
+
store[0] = value
|
|
2773
|
+
store[0].should be_equal(value)
|
|
2774
|
+
end
|
|
2775
|
+
|
|
2776
|
+
it 'guarantees that the same value is retrieved' do
|
|
2777
|
+
value = Value.new(:objval2)
|
|
2778
|
+
store[nil] = value
|
|
2779
|
+
store[nil].should be_equal(value)
|
|
2696
2780
|
end
|
|
2697
2781
|
end
|
|
2698
2782
|
|
|
@@ -4449,26 +4533,54 @@ end
|
|
|
4449
4533
|
shared_examples_for 'returndifferent_integerkey_stringvalue' do
|
|
4450
4534
|
it 'guarantees that a different value is retrieved' do
|
|
4451
4535
|
value = "strval1"
|
|
4452
|
-
store[-10] =
|
|
4453
|
-
store[-10].should_not be_equal(
|
|
4536
|
+
store[-10] = value
|
|
4537
|
+
store[-10].should_not be_equal(value)
|
|
4454
4538
|
end
|
|
4455
4539
|
|
|
4456
4540
|
it 'guarantees that a different value is retrieved' do
|
|
4457
4541
|
value = "strval1"
|
|
4458
|
-
store[42] =
|
|
4459
|
-
store[42].should_not be_equal(
|
|
4542
|
+
store[42] = value
|
|
4543
|
+
store[42].should_not be_equal(value)
|
|
4460
4544
|
end
|
|
4461
4545
|
|
|
4462
4546
|
it 'guarantees that a different value is retrieved' do
|
|
4463
4547
|
value = "strval2"
|
|
4464
|
-
store[-10] =
|
|
4465
|
-
store[-10].should_not be_equal(
|
|
4548
|
+
store[-10] = value
|
|
4549
|
+
store[-10].should_not be_equal(value)
|
|
4466
4550
|
end
|
|
4467
4551
|
|
|
4468
4552
|
it 'guarantees that a different value is retrieved' do
|
|
4469
4553
|
value = "strval2"
|
|
4470
|
-
store[42] =
|
|
4471
|
-
store[42].should_not be_equal(
|
|
4554
|
+
store[42] = value
|
|
4555
|
+
store[42].should_not be_equal(value)
|
|
4556
|
+
end
|
|
4557
|
+
end
|
|
4558
|
+
|
|
4559
|
+
#################### returnsame_integerkey_stringvalue ####################
|
|
4560
|
+
|
|
4561
|
+
shared_examples_for 'returnsame_integerkey_stringvalue' do
|
|
4562
|
+
it 'guarantees that the same value is retrieved' do
|
|
4563
|
+
value = "strval1"
|
|
4564
|
+
store[-10] = value
|
|
4565
|
+
store[-10].should be_equal(value)
|
|
4566
|
+
end
|
|
4567
|
+
|
|
4568
|
+
it 'guarantees that the same value is retrieved' do
|
|
4569
|
+
value = "strval1"
|
|
4570
|
+
store[42] = value
|
|
4571
|
+
store[42].should be_equal(value)
|
|
4572
|
+
end
|
|
4573
|
+
|
|
4574
|
+
it 'guarantees that the same value is retrieved' do
|
|
4575
|
+
value = "strval2"
|
|
4576
|
+
store[-10] = value
|
|
4577
|
+
store[-10].should be_equal(value)
|
|
4578
|
+
end
|
|
4579
|
+
|
|
4580
|
+
it 'guarantees that the same value is retrieved' do
|
|
4581
|
+
value = "strval2"
|
|
4582
|
+
store[42] = value
|
|
4583
|
+
store[42].should be_equal(value)
|
|
4472
4584
|
end
|
|
4473
4585
|
end
|
|
4474
4586
|
|
|
@@ -4925,26 +5037,54 @@ end
|
|
|
4925
5037
|
shared_examples_for 'returndifferent_integerkey_hashvalue' do
|
|
4926
5038
|
it 'guarantees that a different value is retrieved' do
|
|
4927
5039
|
value = {"hashval1"=>["array1", 1]}
|
|
4928
|
-
store[-10] =
|
|
4929
|
-
store[-10].should_not be_equal(
|
|
5040
|
+
store[-10] = value
|
|
5041
|
+
store[-10].should_not be_equal(value)
|
|
4930
5042
|
end
|
|
4931
5043
|
|
|
4932
5044
|
it 'guarantees that a different value is retrieved' do
|
|
4933
5045
|
value = {"hashval1"=>["array1", 1]}
|
|
4934
|
-
store[42] =
|
|
4935
|
-
store[42].should_not be_equal(
|
|
5046
|
+
store[42] = value
|
|
5047
|
+
store[42].should_not be_equal(value)
|
|
4936
5048
|
end
|
|
4937
5049
|
|
|
4938
5050
|
it 'guarantees that a different value is retrieved' do
|
|
4939
5051
|
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
4940
|
-
store[-10] =
|
|
4941
|
-
store[-10].should_not be_equal(
|
|
5052
|
+
store[-10] = value
|
|
5053
|
+
store[-10].should_not be_equal(value)
|
|
4942
5054
|
end
|
|
4943
5055
|
|
|
4944
5056
|
it 'guarantees that a different value is retrieved' do
|
|
4945
5057
|
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
4946
|
-
store[42] =
|
|
4947
|
-
store[42].should_not be_equal(
|
|
5058
|
+
store[42] = value
|
|
5059
|
+
store[42].should_not be_equal(value)
|
|
5060
|
+
end
|
|
5061
|
+
end
|
|
5062
|
+
|
|
5063
|
+
#################### returnsame_integerkey_hashvalue ####################
|
|
5064
|
+
|
|
5065
|
+
shared_examples_for 'returnsame_integerkey_hashvalue' do
|
|
5066
|
+
it 'guarantees that the same value is retrieved' do
|
|
5067
|
+
value = {"hashval1"=>["array1", 1]}
|
|
5068
|
+
store[-10] = value
|
|
5069
|
+
store[-10].should be_equal(value)
|
|
5070
|
+
end
|
|
5071
|
+
|
|
5072
|
+
it 'guarantees that the same value is retrieved' do
|
|
5073
|
+
value = {"hashval1"=>["array1", 1]}
|
|
5074
|
+
store[42] = value
|
|
5075
|
+
store[42].should be_equal(value)
|
|
5076
|
+
end
|
|
5077
|
+
|
|
5078
|
+
it 'guarantees that the same value is retrieved' do
|
|
5079
|
+
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
5080
|
+
store[-10] = value
|
|
5081
|
+
store[-10].should be_equal(value)
|
|
5082
|
+
end
|
|
5083
|
+
|
|
5084
|
+
it 'guarantees that the same value is retrieved' do
|
|
5085
|
+
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
5086
|
+
store[42] = value
|
|
5087
|
+
store[42].should be_equal(value)
|
|
4948
5088
|
end
|
|
4949
5089
|
end
|
|
4950
5090
|
|
|
@@ -5401,26 +5541,54 @@ end
|
|
|
5401
5541
|
shared_examples_for 'returndifferent_integerkey_objectvalue' do
|
|
5402
5542
|
it 'guarantees that a different value is retrieved' do
|
|
5403
5543
|
value = Value.new(:objval1)
|
|
5404
|
-
store[-10] =
|
|
5405
|
-
store[-10].should_not be_equal(
|
|
5544
|
+
store[-10] = value
|
|
5545
|
+
store[-10].should_not be_equal(value)
|
|
5406
5546
|
end
|
|
5407
5547
|
|
|
5408
5548
|
it 'guarantees that a different value is retrieved' do
|
|
5409
5549
|
value = Value.new(:objval1)
|
|
5410
|
-
store[42] =
|
|
5411
|
-
store[42].should_not be_equal(
|
|
5550
|
+
store[42] = value
|
|
5551
|
+
store[42].should_not be_equal(value)
|
|
5412
5552
|
end
|
|
5413
5553
|
|
|
5414
5554
|
it 'guarantees that a different value is retrieved' do
|
|
5415
5555
|
value = Value.new(:objval2)
|
|
5416
|
-
store[-10] =
|
|
5417
|
-
store[-10].should_not be_equal(
|
|
5556
|
+
store[-10] = value
|
|
5557
|
+
store[-10].should_not be_equal(value)
|
|
5418
5558
|
end
|
|
5419
5559
|
|
|
5420
5560
|
it 'guarantees that a different value is retrieved' do
|
|
5421
5561
|
value = Value.new(:objval2)
|
|
5422
|
-
store[42] =
|
|
5423
|
-
store[42].should_not be_equal(
|
|
5562
|
+
store[42] = value
|
|
5563
|
+
store[42].should_not be_equal(value)
|
|
5564
|
+
end
|
|
5565
|
+
end
|
|
5566
|
+
|
|
5567
|
+
#################### returnsame_integerkey_objectvalue ####################
|
|
5568
|
+
|
|
5569
|
+
shared_examples_for 'returnsame_integerkey_objectvalue' do
|
|
5570
|
+
it 'guarantees that the same value is retrieved' do
|
|
5571
|
+
value = Value.new(:objval1)
|
|
5572
|
+
store[-10] = value
|
|
5573
|
+
store[-10].should be_equal(value)
|
|
5574
|
+
end
|
|
5575
|
+
|
|
5576
|
+
it 'guarantees that the same value is retrieved' do
|
|
5577
|
+
value = Value.new(:objval1)
|
|
5578
|
+
store[42] = value
|
|
5579
|
+
store[42].should be_equal(value)
|
|
5580
|
+
end
|
|
5581
|
+
|
|
5582
|
+
it 'guarantees that the same value is retrieved' do
|
|
5583
|
+
value = Value.new(:objval2)
|
|
5584
|
+
store[-10] = value
|
|
5585
|
+
store[-10].should be_equal(value)
|
|
5586
|
+
end
|
|
5587
|
+
|
|
5588
|
+
it 'guarantees that the same value is retrieved' do
|
|
5589
|
+
value = Value.new(:objval2)
|
|
5590
|
+
store[42] = value
|
|
5591
|
+
store[42].should be_equal(value)
|
|
5424
5592
|
end
|
|
5425
5593
|
end
|
|
5426
5594
|
|
|
@@ -7177,26 +7345,54 @@ end
|
|
|
7177
7345
|
shared_examples_for 'returndifferent_booleankey_stringvalue' do
|
|
7178
7346
|
it 'guarantees that a different value is retrieved' do
|
|
7179
7347
|
value = "strval1"
|
|
7180
|
-
store[true] =
|
|
7181
|
-
store[true].should_not be_equal(
|
|
7348
|
+
store[true] = value
|
|
7349
|
+
store[true].should_not be_equal(value)
|
|
7182
7350
|
end
|
|
7183
7351
|
|
|
7184
7352
|
it 'guarantees that a different value is retrieved' do
|
|
7185
7353
|
value = "strval1"
|
|
7186
|
-
store[false] =
|
|
7187
|
-
store[false].should_not be_equal(
|
|
7354
|
+
store[false] = value
|
|
7355
|
+
store[false].should_not be_equal(value)
|
|
7188
7356
|
end
|
|
7189
7357
|
|
|
7190
7358
|
it 'guarantees that a different value is retrieved' do
|
|
7191
7359
|
value = "strval2"
|
|
7192
|
-
store[true] =
|
|
7193
|
-
store[true].should_not be_equal(
|
|
7360
|
+
store[true] = value
|
|
7361
|
+
store[true].should_not be_equal(value)
|
|
7194
7362
|
end
|
|
7195
7363
|
|
|
7196
7364
|
it 'guarantees that a different value is retrieved' do
|
|
7197
7365
|
value = "strval2"
|
|
7198
|
-
store[false] =
|
|
7199
|
-
store[false].should_not be_equal(
|
|
7366
|
+
store[false] = value
|
|
7367
|
+
store[false].should_not be_equal(value)
|
|
7368
|
+
end
|
|
7369
|
+
end
|
|
7370
|
+
|
|
7371
|
+
#################### returnsame_booleankey_stringvalue ####################
|
|
7372
|
+
|
|
7373
|
+
shared_examples_for 'returnsame_booleankey_stringvalue' do
|
|
7374
|
+
it 'guarantees that the same value is retrieved' do
|
|
7375
|
+
value = "strval1"
|
|
7376
|
+
store[true] = value
|
|
7377
|
+
store[true].should be_equal(value)
|
|
7378
|
+
end
|
|
7379
|
+
|
|
7380
|
+
it 'guarantees that the same value is retrieved' do
|
|
7381
|
+
value = "strval1"
|
|
7382
|
+
store[false] = value
|
|
7383
|
+
store[false].should be_equal(value)
|
|
7384
|
+
end
|
|
7385
|
+
|
|
7386
|
+
it 'guarantees that the same value is retrieved' do
|
|
7387
|
+
value = "strval2"
|
|
7388
|
+
store[true] = value
|
|
7389
|
+
store[true].should be_equal(value)
|
|
7390
|
+
end
|
|
7391
|
+
|
|
7392
|
+
it 'guarantees that the same value is retrieved' do
|
|
7393
|
+
value = "strval2"
|
|
7394
|
+
store[false] = value
|
|
7395
|
+
store[false].should be_equal(value)
|
|
7200
7396
|
end
|
|
7201
7397
|
end
|
|
7202
7398
|
|
|
@@ -7653,26 +7849,54 @@ end
|
|
|
7653
7849
|
shared_examples_for 'returndifferent_booleankey_hashvalue' do
|
|
7654
7850
|
it 'guarantees that a different value is retrieved' do
|
|
7655
7851
|
value = {"hashval1"=>["array1", 1]}
|
|
7656
|
-
store[true] =
|
|
7657
|
-
store[true].should_not be_equal(
|
|
7852
|
+
store[true] = value
|
|
7853
|
+
store[true].should_not be_equal(value)
|
|
7658
7854
|
end
|
|
7659
7855
|
|
|
7660
7856
|
it 'guarantees that a different value is retrieved' do
|
|
7661
7857
|
value = {"hashval1"=>["array1", 1]}
|
|
7662
|
-
store[false] =
|
|
7663
|
-
store[false].should_not be_equal(
|
|
7858
|
+
store[false] = value
|
|
7859
|
+
store[false].should_not be_equal(value)
|
|
7664
7860
|
end
|
|
7665
7861
|
|
|
7666
7862
|
it 'guarantees that a different value is retrieved' do
|
|
7667
7863
|
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
7668
|
-
store[true] =
|
|
7669
|
-
store[true].should_not be_equal(
|
|
7864
|
+
store[true] = value
|
|
7865
|
+
store[true].should_not be_equal(value)
|
|
7670
7866
|
end
|
|
7671
7867
|
|
|
7672
7868
|
it 'guarantees that a different value is retrieved' do
|
|
7673
7869
|
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
7674
|
-
store[false] =
|
|
7675
|
-
store[false].should_not be_equal(
|
|
7870
|
+
store[false] = value
|
|
7871
|
+
store[false].should_not be_equal(value)
|
|
7872
|
+
end
|
|
7873
|
+
end
|
|
7874
|
+
|
|
7875
|
+
#################### returnsame_booleankey_hashvalue ####################
|
|
7876
|
+
|
|
7877
|
+
shared_examples_for 'returnsame_booleankey_hashvalue' do
|
|
7878
|
+
it 'guarantees that the same value is retrieved' do
|
|
7879
|
+
value = {"hashval1"=>["array1", 1]}
|
|
7880
|
+
store[true] = value
|
|
7881
|
+
store[true].should be_equal(value)
|
|
7882
|
+
end
|
|
7883
|
+
|
|
7884
|
+
it 'guarantees that the same value is retrieved' do
|
|
7885
|
+
value = {"hashval1"=>["array1", 1]}
|
|
7886
|
+
store[false] = value
|
|
7887
|
+
store[false].should be_equal(value)
|
|
7888
|
+
end
|
|
7889
|
+
|
|
7890
|
+
it 'guarantees that the same value is retrieved' do
|
|
7891
|
+
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
7892
|
+
store[true] = value
|
|
7893
|
+
store[true].should be_equal(value)
|
|
7894
|
+
end
|
|
7895
|
+
|
|
7896
|
+
it 'guarantees that the same value is retrieved' do
|
|
7897
|
+
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
7898
|
+
store[false] = value
|
|
7899
|
+
store[false].should be_equal(value)
|
|
7676
7900
|
end
|
|
7677
7901
|
end
|
|
7678
7902
|
|
|
@@ -8129,26 +8353,54 @@ end
|
|
|
8129
8353
|
shared_examples_for 'returndifferent_booleankey_objectvalue' do
|
|
8130
8354
|
it 'guarantees that a different value is retrieved' do
|
|
8131
8355
|
value = Value.new(:objval1)
|
|
8132
|
-
store[true] =
|
|
8133
|
-
store[true].should_not be_equal(
|
|
8356
|
+
store[true] = value
|
|
8357
|
+
store[true].should_not be_equal(value)
|
|
8134
8358
|
end
|
|
8135
8359
|
|
|
8136
8360
|
it 'guarantees that a different value is retrieved' do
|
|
8137
8361
|
value = Value.new(:objval1)
|
|
8138
|
-
store[false] =
|
|
8139
|
-
store[false].should_not be_equal(
|
|
8362
|
+
store[false] = value
|
|
8363
|
+
store[false].should_not be_equal(value)
|
|
8140
8364
|
end
|
|
8141
8365
|
|
|
8142
8366
|
it 'guarantees that a different value is retrieved' do
|
|
8143
8367
|
value = Value.new(:objval2)
|
|
8144
|
-
store[true] =
|
|
8145
|
-
store[true].should_not be_equal(
|
|
8368
|
+
store[true] = value
|
|
8369
|
+
store[true].should_not be_equal(value)
|
|
8146
8370
|
end
|
|
8147
8371
|
|
|
8148
8372
|
it 'guarantees that a different value is retrieved' do
|
|
8149
8373
|
value = Value.new(:objval2)
|
|
8150
|
-
store[false] =
|
|
8151
|
-
store[false].should_not be_equal(
|
|
8374
|
+
store[false] = value
|
|
8375
|
+
store[false].should_not be_equal(value)
|
|
8376
|
+
end
|
|
8377
|
+
end
|
|
8378
|
+
|
|
8379
|
+
#################### returnsame_booleankey_objectvalue ####################
|
|
8380
|
+
|
|
8381
|
+
shared_examples_for 'returnsame_booleankey_objectvalue' do
|
|
8382
|
+
it 'guarantees that the same value is retrieved' do
|
|
8383
|
+
value = Value.new(:objval1)
|
|
8384
|
+
store[true] = value
|
|
8385
|
+
store[true].should be_equal(value)
|
|
8386
|
+
end
|
|
8387
|
+
|
|
8388
|
+
it 'guarantees that the same value is retrieved' do
|
|
8389
|
+
value = Value.new(:objval1)
|
|
8390
|
+
store[false] = value
|
|
8391
|
+
store[false].should be_equal(value)
|
|
8392
|
+
end
|
|
8393
|
+
|
|
8394
|
+
it 'guarantees that the same value is retrieved' do
|
|
8395
|
+
value = Value.new(:objval2)
|
|
8396
|
+
store[true] = value
|
|
8397
|
+
store[true].should be_equal(value)
|
|
8398
|
+
end
|
|
8399
|
+
|
|
8400
|
+
it 'guarantees that the same value is retrieved' do
|
|
8401
|
+
value = Value.new(:objval2)
|
|
8402
|
+
store[false] = value
|
|
8403
|
+
store[false].should be_equal(value)
|
|
8152
8404
|
end
|
|
8153
8405
|
end
|
|
8154
8406
|
|
|
@@ -9905,26 +10157,54 @@ end
|
|
|
9905
10157
|
shared_examples_for 'returndifferent_stringkey_stringvalue' do
|
|
9906
10158
|
it 'guarantees that a different value is retrieved' do
|
|
9907
10159
|
value = "strval1"
|
|
9908
|
-
store["strkey1"] =
|
|
9909
|
-
store["strkey1"].should_not be_equal(
|
|
10160
|
+
store["strkey1"] = value
|
|
10161
|
+
store["strkey1"].should_not be_equal(value)
|
|
9910
10162
|
end
|
|
9911
10163
|
|
|
9912
10164
|
it 'guarantees that a different value is retrieved' do
|
|
9913
10165
|
value = "strval1"
|
|
9914
|
-
store["strkey2"] =
|
|
9915
|
-
store["strkey2"].should_not be_equal(
|
|
10166
|
+
store["strkey2"] = value
|
|
10167
|
+
store["strkey2"].should_not be_equal(value)
|
|
9916
10168
|
end
|
|
9917
10169
|
|
|
9918
10170
|
it 'guarantees that a different value is retrieved' do
|
|
9919
10171
|
value = "strval2"
|
|
9920
|
-
store["strkey1"] =
|
|
9921
|
-
store["strkey1"].should_not be_equal(
|
|
10172
|
+
store["strkey1"] = value
|
|
10173
|
+
store["strkey1"].should_not be_equal(value)
|
|
9922
10174
|
end
|
|
9923
10175
|
|
|
9924
10176
|
it 'guarantees that a different value is retrieved' do
|
|
9925
10177
|
value = "strval2"
|
|
9926
|
-
store["strkey2"] =
|
|
9927
|
-
store["strkey2"].should_not be_equal(
|
|
10178
|
+
store["strkey2"] = value
|
|
10179
|
+
store["strkey2"].should_not be_equal(value)
|
|
10180
|
+
end
|
|
10181
|
+
end
|
|
10182
|
+
|
|
10183
|
+
#################### returnsame_stringkey_stringvalue ####################
|
|
10184
|
+
|
|
10185
|
+
shared_examples_for 'returnsame_stringkey_stringvalue' do
|
|
10186
|
+
it 'guarantees that the same value is retrieved' do
|
|
10187
|
+
value = "strval1"
|
|
10188
|
+
store["strkey1"] = value
|
|
10189
|
+
store["strkey1"].should be_equal(value)
|
|
10190
|
+
end
|
|
10191
|
+
|
|
10192
|
+
it 'guarantees that the same value is retrieved' do
|
|
10193
|
+
value = "strval1"
|
|
10194
|
+
store["strkey2"] = value
|
|
10195
|
+
store["strkey2"].should be_equal(value)
|
|
10196
|
+
end
|
|
10197
|
+
|
|
10198
|
+
it 'guarantees that the same value is retrieved' do
|
|
10199
|
+
value = "strval2"
|
|
10200
|
+
store["strkey1"] = value
|
|
10201
|
+
store["strkey1"].should be_equal(value)
|
|
10202
|
+
end
|
|
10203
|
+
|
|
10204
|
+
it 'guarantees that the same value is retrieved' do
|
|
10205
|
+
value = "strval2"
|
|
10206
|
+
store["strkey2"] = value
|
|
10207
|
+
store["strkey2"].should be_equal(value)
|
|
9928
10208
|
end
|
|
9929
10209
|
end
|
|
9930
10210
|
|
|
@@ -10381,26 +10661,54 @@ end
|
|
|
10381
10661
|
shared_examples_for 'returndifferent_stringkey_hashvalue' do
|
|
10382
10662
|
it 'guarantees that a different value is retrieved' do
|
|
10383
10663
|
value = {"hashval1"=>["array1", 1]}
|
|
10384
|
-
store["strkey1"] =
|
|
10385
|
-
store["strkey1"].should_not be_equal(
|
|
10664
|
+
store["strkey1"] = value
|
|
10665
|
+
store["strkey1"].should_not be_equal(value)
|
|
10386
10666
|
end
|
|
10387
10667
|
|
|
10388
10668
|
it 'guarantees that a different value is retrieved' do
|
|
10389
10669
|
value = {"hashval1"=>["array1", 1]}
|
|
10390
|
-
store["strkey2"] =
|
|
10391
|
-
store["strkey2"].should_not be_equal(
|
|
10670
|
+
store["strkey2"] = value
|
|
10671
|
+
store["strkey2"].should_not be_equal(value)
|
|
10392
10672
|
end
|
|
10393
10673
|
|
|
10394
10674
|
it 'guarantees that a different value is retrieved' do
|
|
10395
10675
|
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
10396
|
-
store["strkey1"] =
|
|
10397
|
-
store["strkey1"].should_not be_equal(
|
|
10676
|
+
store["strkey1"] = value
|
|
10677
|
+
store["strkey1"].should_not be_equal(value)
|
|
10398
10678
|
end
|
|
10399
10679
|
|
|
10400
10680
|
it 'guarantees that a different value is retrieved' do
|
|
10401
10681
|
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
10402
|
-
store["strkey2"] =
|
|
10403
|
-
store["strkey2"].should_not be_equal(
|
|
10682
|
+
store["strkey2"] = value
|
|
10683
|
+
store["strkey2"].should_not be_equal(value)
|
|
10684
|
+
end
|
|
10685
|
+
end
|
|
10686
|
+
|
|
10687
|
+
#################### returnsame_stringkey_hashvalue ####################
|
|
10688
|
+
|
|
10689
|
+
shared_examples_for 'returnsame_stringkey_hashvalue' do
|
|
10690
|
+
it 'guarantees that the same value is retrieved' do
|
|
10691
|
+
value = {"hashval1"=>["array1", 1]}
|
|
10692
|
+
store["strkey1"] = value
|
|
10693
|
+
store["strkey1"].should be_equal(value)
|
|
10694
|
+
end
|
|
10695
|
+
|
|
10696
|
+
it 'guarantees that the same value is retrieved' do
|
|
10697
|
+
value = {"hashval1"=>["array1", 1]}
|
|
10698
|
+
store["strkey2"] = value
|
|
10699
|
+
store["strkey2"].should be_equal(value)
|
|
10700
|
+
end
|
|
10701
|
+
|
|
10702
|
+
it 'guarantees that the same value is retrieved' do
|
|
10703
|
+
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
10704
|
+
store["strkey1"] = value
|
|
10705
|
+
store["strkey1"].should be_equal(value)
|
|
10706
|
+
end
|
|
10707
|
+
|
|
10708
|
+
it 'guarantees that the same value is retrieved' do
|
|
10709
|
+
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
10710
|
+
store["strkey2"] = value
|
|
10711
|
+
store["strkey2"].should be_equal(value)
|
|
10404
10712
|
end
|
|
10405
10713
|
end
|
|
10406
10714
|
|
|
@@ -10857,26 +11165,54 @@ end
|
|
|
10857
11165
|
shared_examples_for 'returndifferent_stringkey_objectvalue' do
|
|
10858
11166
|
it 'guarantees that a different value is retrieved' do
|
|
10859
11167
|
value = Value.new(:objval1)
|
|
10860
|
-
store["strkey1"] =
|
|
10861
|
-
store["strkey1"].should_not be_equal(
|
|
11168
|
+
store["strkey1"] = value
|
|
11169
|
+
store["strkey1"].should_not be_equal(value)
|
|
10862
11170
|
end
|
|
10863
11171
|
|
|
10864
11172
|
it 'guarantees that a different value is retrieved' do
|
|
10865
11173
|
value = Value.new(:objval1)
|
|
10866
|
-
store["strkey2"] =
|
|
10867
|
-
store["strkey2"].should_not be_equal(
|
|
11174
|
+
store["strkey2"] = value
|
|
11175
|
+
store["strkey2"].should_not be_equal(value)
|
|
10868
11176
|
end
|
|
10869
11177
|
|
|
10870
11178
|
it 'guarantees that a different value is retrieved' do
|
|
10871
11179
|
value = Value.new(:objval2)
|
|
10872
|
-
store["strkey1"] =
|
|
10873
|
-
store["strkey1"].should_not be_equal(
|
|
11180
|
+
store["strkey1"] = value
|
|
11181
|
+
store["strkey1"].should_not be_equal(value)
|
|
10874
11182
|
end
|
|
10875
11183
|
|
|
10876
11184
|
it 'guarantees that a different value is retrieved' do
|
|
10877
11185
|
value = Value.new(:objval2)
|
|
10878
|
-
store["strkey2"] =
|
|
10879
|
-
store["strkey2"].should_not be_equal(
|
|
11186
|
+
store["strkey2"] = value
|
|
11187
|
+
store["strkey2"].should_not be_equal(value)
|
|
11188
|
+
end
|
|
11189
|
+
end
|
|
11190
|
+
|
|
11191
|
+
#################### returnsame_stringkey_objectvalue ####################
|
|
11192
|
+
|
|
11193
|
+
shared_examples_for 'returnsame_stringkey_objectvalue' do
|
|
11194
|
+
it 'guarantees that the same value is retrieved' do
|
|
11195
|
+
value = Value.new(:objval1)
|
|
11196
|
+
store["strkey1"] = value
|
|
11197
|
+
store["strkey1"].should be_equal(value)
|
|
11198
|
+
end
|
|
11199
|
+
|
|
11200
|
+
it 'guarantees that the same value is retrieved' do
|
|
11201
|
+
value = Value.new(:objval1)
|
|
11202
|
+
store["strkey2"] = value
|
|
11203
|
+
store["strkey2"].should be_equal(value)
|
|
11204
|
+
end
|
|
11205
|
+
|
|
11206
|
+
it 'guarantees that the same value is retrieved' do
|
|
11207
|
+
value = Value.new(:objval2)
|
|
11208
|
+
store["strkey1"] = value
|
|
11209
|
+
store["strkey1"].should be_equal(value)
|
|
11210
|
+
end
|
|
11211
|
+
|
|
11212
|
+
it 'guarantees that the same value is retrieved' do
|
|
11213
|
+
value = Value.new(:objval2)
|
|
11214
|
+
store["strkey2"] = value
|
|
11215
|
+
store["strkey2"].should be_equal(value)
|
|
10880
11216
|
end
|
|
10881
11217
|
end
|
|
10882
11218
|
|
|
@@ -12633,26 +12969,54 @@ end
|
|
|
12633
12969
|
shared_examples_for 'returndifferent_objectkey_stringvalue' do
|
|
12634
12970
|
it 'guarantees that a different value is retrieved' do
|
|
12635
12971
|
value = "strval1"
|
|
12636
|
-
store[Value.new(:objkey1)] =
|
|
12637
|
-
store[Value.new(:objkey1)].should_not be_equal(
|
|
12972
|
+
store[Value.new(:objkey1)] = value
|
|
12973
|
+
store[Value.new(:objkey1)].should_not be_equal(value)
|
|
12638
12974
|
end
|
|
12639
12975
|
|
|
12640
12976
|
it 'guarantees that a different value is retrieved' do
|
|
12641
12977
|
value = "strval1"
|
|
12642
|
-
store[Value.new(:objkey2)] =
|
|
12643
|
-
store[Value.new(:objkey2)].should_not be_equal(
|
|
12978
|
+
store[Value.new(:objkey2)] = value
|
|
12979
|
+
store[Value.new(:objkey2)].should_not be_equal(value)
|
|
12644
12980
|
end
|
|
12645
12981
|
|
|
12646
12982
|
it 'guarantees that a different value is retrieved' do
|
|
12647
12983
|
value = "strval2"
|
|
12648
|
-
store[Value.new(:objkey1)] =
|
|
12649
|
-
store[Value.new(:objkey1)].should_not be_equal(
|
|
12984
|
+
store[Value.new(:objkey1)] = value
|
|
12985
|
+
store[Value.new(:objkey1)].should_not be_equal(value)
|
|
12650
12986
|
end
|
|
12651
12987
|
|
|
12652
12988
|
it 'guarantees that a different value is retrieved' do
|
|
12653
12989
|
value = "strval2"
|
|
12654
|
-
store[Value.new(:objkey2)] =
|
|
12655
|
-
store[Value.new(:objkey2)].should_not be_equal(
|
|
12990
|
+
store[Value.new(:objkey2)] = value
|
|
12991
|
+
store[Value.new(:objkey2)].should_not be_equal(value)
|
|
12992
|
+
end
|
|
12993
|
+
end
|
|
12994
|
+
|
|
12995
|
+
#################### returnsame_objectkey_stringvalue ####################
|
|
12996
|
+
|
|
12997
|
+
shared_examples_for 'returnsame_objectkey_stringvalue' do
|
|
12998
|
+
it 'guarantees that the same value is retrieved' do
|
|
12999
|
+
value = "strval1"
|
|
13000
|
+
store[Value.new(:objkey1)] = value
|
|
13001
|
+
store[Value.new(:objkey1)].should be_equal(value)
|
|
13002
|
+
end
|
|
13003
|
+
|
|
13004
|
+
it 'guarantees that the same value is retrieved' do
|
|
13005
|
+
value = "strval1"
|
|
13006
|
+
store[Value.new(:objkey2)] = value
|
|
13007
|
+
store[Value.new(:objkey2)].should be_equal(value)
|
|
13008
|
+
end
|
|
13009
|
+
|
|
13010
|
+
it 'guarantees that the same value is retrieved' do
|
|
13011
|
+
value = "strval2"
|
|
13012
|
+
store[Value.new(:objkey1)] = value
|
|
13013
|
+
store[Value.new(:objkey1)].should be_equal(value)
|
|
13014
|
+
end
|
|
13015
|
+
|
|
13016
|
+
it 'guarantees that the same value is retrieved' do
|
|
13017
|
+
value = "strval2"
|
|
13018
|
+
store[Value.new(:objkey2)] = value
|
|
13019
|
+
store[Value.new(:objkey2)].should be_equal(value)
|
|
12656
13020
|
end
|
|
12657
13021
|
end
|
|
12658
13022
|
|
|
@@ -13109,26 +13473,54 @@ end
|
|
|
13109
13473
|
shared_examples_for 'returndifferent_objectkey_hashvalue' do
|
|
13110
13474
|
it 'guarantees that a different value is retrieved' do
|
|
13111
13475
|
value = {"hashval1"=>["array1", 1]}
|
|
13112
|
-
store[Value.new(:objkey1)] =
|
|
13113
|
-
store[Value.new(:objkey1)].should_not be_equal(
|
|
13476
|
+
store[Value.new(:objkey1)] = value
|
|
13477
|
+
store[Value.new(:objkey1)].should_not be_equal(value)
|
|
13114
13478
|
end
|
|
13115
13479
|
|
|
13116
13480
|
it 'guarantees that a different value is retrieved' do
|
|
13117
13481
|
value = {"hashval1"=>["array1", 1]}
|
|
13118
|
-
store[Value.new(:objkey2)] =
|
|
13119
|
-
store[Value.new(:objkey2)].should_not be_equal(
|
|
13482
|
+
store[Value.new(:objkey2)] = value
|
|
13483
|
+
store[Value.new(:objkey2)].should_not be_equal(value)
|
|
13120
13484
|
end
|
|
13121
13485
|
|
|
13122
13486
|
it 'guarantees that a different value is retrieved' do
|
|
13123
13487
|
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
13124
|
-
store[Value.new(:objkey1)] =
|
|
13125
|
-
store[Value.new(:objkey1)].should_not be_equal(
|
|
13488
|
+
store[Value.new(:objkey1)] = value
|
|
13489
|
+
store[Value.new(:objkey1)].should_not be_equal(value)
|
|
13126
13490
|
end
|
|
13127
13491
|
|
|
13128
13492
|
it 'guarantees that a different value is retrieved' do
|
|
13129
13493
|
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
13130
|
-
store[Value.new(:objkey2)] =
|
|
13131
|
-
store[Value.new(:objkey2)].should_not be_equal(
|
|
13494
|
+
store[Value.new(:objkey2)] = value
|
|
13495
|
+
store[Value.new(:objkey2)].should_not be_equal(value)
|
|
13496
|
+
end
|
|
13497
|
+
end
|
|
13498
|
+
|
|
13499
|
+
#################### returnsame_objectkey_hashvalue ####################
|
|
13500
|
+
|
|
13501
|
+
shared_examples_for 'returnsame_objectkey_hashvalue' do
|
|
13502
|
+
it 'guarantees that the same value is retrieved' do
|
|
13503
|
+
value = {"hashval1"=>["array1", 1]}
|
|
13504
|
+
store[Value.new(:objkey1)] = value
|
|
13505
|
+
store[Value.new(:objkey1)].should be_equal(value)
|
|
13506
|
+
end
|
|
13507
|
+
|
|
13508
|
+
it 'guarantees that the same value is retrieved' do
|
|
13509
|
+
value = {"hashval1"=>["array1", 1]}
|
|
13510
|
+
store[Value.new(:objkey2)] = value
|
|
13511
|
+
store[Value.new(:objkey2)].should be_equal(value)
|
|
13512
|
+
end
|
|
13513
|
+
|
|
13514
|
+
it 'guarantees that the same value is retrieved' do
|
|
13515
|
+
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
13516
|
+
store[Value.new(:objkey1)] = value
|
|
13517
|
+
store[Value.new(:objkey1)].should be_equal(value)
|
|
13518
|
+
end
|
|
13519
|
+
|
|
13520
|
+
it 'guarantees that the same value is retrieved' do
|
|
13521
|
+
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
13522
|
+
store[Value.new(:objkey2)] = value
|
|
13523
|
+
store[Value.new(:objkey2)].should be_equal(value)
|
|
13132
13524
|
end
|
|
13133
13525
|
end
|
|
13134
13526
|
|
|
@@ -13585,26 +13977,54 @@ end
|
|
|
13585
13977
|
shared_examples_for 'returndifferent_objectkey_objectvalue' do
|
|
13586
13978
|
it 'guarantees that a different value is retrieved' do
|
|
13587
13979
|
value = Value.new(:objval1)
|
|
13588
|
-
store[Value.new(:objkey1)] =
|
|
13589
|
-
store[Value.new(:objkey1)].should_not be_equal(
|
|
13980
|
+
store[Value.new(:objkey1)] = value
|
|
13981
|
+
store[Value.new(:objkey1)].should_not be_equal(value)
|
|
13590
13982
|
end
|
|
13591
13983
|
|
|
13592
13984
|
it 'guarantees that a different value is retrieved' do
|
|
13593
13985
|
value = Value.new(:objval1)
|
|
13594
|
-
store[Value.new(:objkey2)] =
|
|
13595
|
-
store[Value.new(:objkey2)].should_not be_equal(
|
|
13986
|
+
store[Value.new(:objkey2)] = value
|
|
13987
|
+
store[Value.new(:objkey2)].should_not be_equal(value)
|
|
13596
13988
|
end
|
|
13597
13989
|
|
|
13598
13990
|
it 'guarantees that a different value is retrieved' do
|
|
13599
13991
|
value = Value.new(:objval2)
|
|
13600
|
-
store[Value.new(:objkey1)] =
|
|
13601
|
-
store[Value.new(:objkey1)].should_not be_equal(
|
|
13992
|
+
store[Value.new(:objkey1)] = value
|
|
13993
|
+
store[Value.new(:objkey1)].should_not be_equal(value)
|
|
13602
13994
|
end
|
|
13603
13995
|
|
|
13604
13996
|
it 'guarantees that a different value is retrieved' do
|
|
13605
13997
|
value = Value.new(:objval2)
|
|
13606
|
-
store[Value.new(:objkey2)] =
|
|
13607
|
-
store[Value.new(:objkey2)].should_not be_equal(
|
|
13998
|
+
store[Value.new(:objkey2)] = value
|
|
13999
|
+
store[Value.new(:objkey2)].should_not be_equal(value)
|
|
14000
|
+
end
|
|
14001
|
+
end
|
|
14002
|
+
|
|
14003
|
+
#################### returnsame_objectkey_objectvalue ####################
|
|
14004
|
+
|
|
14005
|
+
shared_examples_for 'returnsame_objectkey_objectvalue' do
|
|
14006
|
+
it 'guarantees that the same value is retrieved' do
|
|
14007
|
+
value = Value.new(:objval1)
|
|
14008
|
+
store[Value.new(:objkey1)] = value
|
|
14009
|
+
store[Value.new(:objkey1)].should be_equal(value)
|
|
14010
|
+
end
|
|
14011
|
+
|
|
14012
|
+
it 'guarantees that the same value is retrieved' do
|
|
14013
|
+
value = Value.new(:objval1)
|
|
14014
|
+
store[Value.new(:objkey2)] = value
|
|
14015
|
+
store[Value.new(:objkey2)].should be_equal(value)
|
|
14016
|
+
end
|
|
14017
|
+
|
|
14018
|
+
it 'guarantees that the same value is retrieved' do
|
|
14019
|
+
value = Value.new(:objval2)
|
|
14020
|
+
store[Value.new(:objkey1)] = value
|
|
14021
|
+
store[Value.new(:objkey1)].should be_equal(value)
|
|
14022
|
+
end
|
|
14023
|
+
|
|
14024
|
+
it 'guarantees that the same value is retrieved' do
|
|
14025
|
+
value = Value.new(:objval2)
|
|
14026
|
+
store[Value.new(:objkey2)] = value
|
|
14027
|
+
store[Value.new(:objkey2)].should be_equal(value)
|
|
13608
14028
|
end
|
|
13609
14029
|
end
|
|
13610
14030
|
|
|
@@ -15361,26 +15781,54 @@ end
|
|
|
15361
15781
|
shared_examples_for 'returndifferent_hashkey_stringvalue' do
|
|
15362
15782
|
it 'guarantees that a different value is retrieved' do
|
|
15363
15783
|
value = "strval1"
|
|
15364
|
-
store[{"hashkey1"=>"hashkey2"}] =
|
|
15365
|
-
store[{"hashkey1"=>"hashkey2"}].should_not be_equal(
|
|
15784
|
+
store[{"hashkey1"=>"hashkey2"}] = value
|
|
15785
|
+
store[{"hashkey1"=>"hashkey2"}].should_not be_equal(value)
|
|
15366
15786
|
end
|
|
15367
15787
|
|
|
15368
15788
|
it 'guarantees that a different value is retrieved' do
|
|
15369
15789
|
value = "strval1"
|
|
15370
|
-
store[{"hashkey3"=>"hashkey4"}] =
|
|
15371
|
-
store[{"hashkey3"=>"hashkey4"}].should_not be_equal(
|
|
15790
|
+
store[{"hashkey3"=>"hashkey4"}] = value
|
|
15791
|
+
store[{"hashkey3"=>"hashkey4"}].should_not be_equal(value)
|
|
15372
15792
|
end
|
|
15373
15793
|
|
|
15374
15794
|
it 'guarantees that a different value is retrieved' do
|
|
15375
15795
|
value = "strval2"
|
|
15376
|
-
store[{"hashkey1"=>"hashkey2"}] =
|
|
15377
|
-
store[{"hashkey1"=>"hashkey2"}].should_not be_equal(
|
|
15796
|
+
store[{"hashkey1"=>"hashkey2"}] = value
|
|
15797
|
+
store[{"hashkey1"=>"hashkey2"}].should_not be_equal(value)
|
|
15378
15798
|
end
|
|
15379
15799
|
|
|
15380
15800
|
it 'guarantees that a different value is retrieved' do
|
|
15381
15801
|
value = "strval2"
|
|
15382
|
-
store[{"hashkey3"=>"hashkey4"}] =
|
|
15383
|
-
store[{"hashkey3"=>"hashkey4"}].should_not be_equal(
|
|
15802
|
+
store[{"hashkey3"=>"hashkey4"}] = value
|
|
15803
|
+
store[{"hashkey3"=>"hashkey4"}].should_not be_equal(value)
|
|
15804
|
+
end
|
|
15805
|
+
end
|
|
15806
|
+
|
|
15807
|
+
#################### returnsame_hashkey_stringvalue ####################
|
|
15808
|
+
|
|
15809
|
+
shared_examples_for 'returnsame_hashkey_stringvalue' do
|
|
15810
|
+
it 'guarantees that the same value is retrieved' do
|
|
15811
|
+
value = "strval1"
|
|
15812
|
+
store[{"hashkey1"=>"hashkey2"}] = value
|
|
15813
|
+
store[{"hashkey1"=>"hashkey2"}].should be_equal(value)
|
|
15814
|
+
end
|
|
15815
|
+
|
|
15816
|
+
it 'guarantees that the same value is retrieved' do
|
|
15817
|
+
value = "strval1"
|
|
15818
|
+
store[{"hashkey3"=>"hashkey4"}] = value
|
|
15819
|
+
store[{"hashkey3"=>"hashkey4"}].should be_equal(value)
|
|
15820
|
+
end
|
|
15821
|
+
|
|
15822
|
+
it 'guarantees that the same value is retrieved' do
|
|
15823
|
+
value = "strval2"
|
|
15824
|
+
store[{"hashkey1"=>"hashkey2"}] = value
|
|
15825
|
+
store[{"hashkey1"=>"hashkey2"}].should be_equal(value)
|
|
15826
|
+
end
|
|
15827
|
+
|
|
15828
|
+
it 'guarantees that the same value is retrieved' do
|
|
15829
|
+
value = "strval2"
|
|
15830
|
+
store[{"hashkey3"=>"hashkey4"}] = value
|
|
15831
|
+
store[{"hashkey3"=>"hashkey4"}].should be_equal(value)
|
|
15384
15832
|
end
|
|
15385
15833
|
end
|
|
15386
15834
|
|
|
@@ -15837,26 +16285,54 @@ end
|
|
|
15837
16285
|
shared_examples_for 'returndifferent_hashkey_hashvalue' do
|
|
15838
16286
|
it 'guarantees that a different value is retrieved' do
|
|
15839
16287
|
value = {"hashval1"=>["array1", 1]}
|
|
15840
|
-
store[{"hashkey1"=>"hashkey2"}] =
|
|
15841
|
-
store[{"hashkey1"=>"hashkey2"}].should_not be_equal(
|
|
16288
|
+
store[{"hashkey1"=>"hashkey2"}] = value
|
|
16289
|
+
store[{"hashkey1"=>"hashkey2"}].should_not be_equal(value)
|
|
15842
16290
|
end
|
|
15843
16291
|
|
|
15844
16292
|
it 'guarantees that a different value is retrieved' do
|
|
15845
16293
|
value = {"hashval1"=>["array1", 1]}
|
|
15846
|
-
store[{"hashkey3"=>"hashkey4"}] =
|
|
15847
|
-
store[{"hashkey3"=>"hashkey4"}].should_not be_equal(
|
|
16294
|
+
store[{"hashkey3"=>"hashkey4"}] = value
|
|
16295
|
+
store[{"hashkey3"=>"hashkey4"}].should_not be_equal(value)
|
|
15848
16296
|
end
|
|
15849
16297
|
|
|
15850
16298
|
it 'guarantees that a different value is retrieved' do
|
|
15851
16299
|
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
15852
|
-
store[{"hashkey1"=>"hashkey2"}] =
|
|
15853
|
-
store[{"hashkey1"=>"hashkey2"}].should_not be_equal(
|
|
16300
|
+
store[{"hashkey1"=>"hashkey2"}] = value
|
|
16301
|
+
store[{"hashkey1"=>"hashkey2"}].should_not be_equal(value)
|
|
15854
16302
|
end
|
|
15855
16303
|
|
|
15856
16304
|
it 'guarantees that a different value is retrieved' do
|
|
15857
16305
|
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
15858
|
-
store[{"hashkey3"=>"hashkey4"}] =
|
|
15859
|
-
store[{"hashkey3"=>"hashkey4"}].should_not be_equal(
|
|
16306
|
+
store[{"hashkey3"=>"hashkey4"}] = value
|
|
16307
|
+
store[{"hashkey3"=>"hashkey4"}].should_not be_equal(value)
|
|
16308
|
+
end
|
|
16309
|
+
end
|
|
16310
|
+
|
|
16311
|
+
#################### returnsame_hashkey_hashvalue ####################
|
|
16312
|
+
|
|
16313
|
+
shared_examples_for 'returnsame_hashkey_hashvalue' do
|
|
16314
|
+
it 'guarantees that the same value is retrieved' do
|
|
16315
|
+
value = {"hashval1"=>["array1", 1]}
|
|
16316
|
+
store[{"hashkey1"=>"hashkey2"}] = value
|
|
16317
|
+
store[{"hashkey1"=>"hashkey2"}].should be_equal(value)
|
|
16318
|
+
end
|
|
16319
|
+
|
|
16320
|
+
it 'guarantees that the same value is retrieved' do
|
|
16321
|
+
value = {"hashval1"=>["array1", 1]}
|
|
16322
|
+
store[{"hashkey3"=>"hashkey4"}] = value
|
|
16323
|
+
store[{"hashkey3"=>"hashkey4"}].should be_equal(value)
|
|
16324
|
+
end
|
|
16325
|
+
|
|
16326
|
+
it 'guarantees that the same value is retrieved' do
|
|
16327
|
+
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
16328
|
+
store[{"hashkey1"=>"hashkey2"}] = value
|
|
16329
|
+
store[{"hashkey1"=>"hashkey2"}].should be_equal(value)
|
|
16330
|
+
end
|
|
16331
|
+
|
|
16332
|
+
it 'guarantees that the same value is retrieved' do
|
|
16333
|
+
value = {"hashval3"=>["array2", {"hashval4"=>42}]}
|
|
16334
|
+
store[{"hashkey3"=>"hashkey4"}] = value
|
|
16335
|
+
store[{"hashkey3"=>"hashkey4"}].should be_equal(value)
|
|
15860
16336
|
end
|
|
15861
16337
|
end
|
|
15862
16338
|
|
|
@@ -16313,26 +16789,54 @@ end
|
|
|
16313
16789
|
shared_examples_for 'returndifferent_hashkey_objectvalue' do
|
|
16314
16790
|
it 'guarantees that a different value is retrieved' do
|
|
16315
16791
|
value = Value.new(:objval1)
|
|
16316
|
-
store[{"hashkey1"=>"hashkey2"}] =
|
|
16317
|
-
store[{"hashkey1"=>"hashkey2"}].should_not be_equal(
|
|
16792
|
+
store[{"hashkey1"=>"hashkey2"}] = value
|
|
16793
|
+
store[{"hashkey1"=>"hashkey2"}].should_not be_equal(value)
|
|
16318
16794
|
end
|
|
16319
16795
|
|
|
16320
16796
|
it 'guarantees that a different value is retrieved' do
|
|
16321
16797
|
value = Value.new(:objval1)
|
|
16322
|
-
store[{"hashkey3"=>"hashkey4"}] =
|
|
16323
|
-
store[{"hashkey3"=>"hashkey4"}].should_not be_equal(
|
|
16798
|
+
store[{"hashkey3"=>"hashkey4"}] = value
|
|
16799
|
+
store[{"hashkey3"=>"hashkey4"}].should_not be_equal(value)
|
|
16324
16800
|
end
|
|
16325
16801
|
|
|
16326
16802
|
it 'guarantees that a different value is retrieved' do
|
|
16327
16803
|
value = Value.new(:objval2)
|
|
16328
|
-
store[{"hashkey1"=>"hashkey2"}] =
|
|
16329
|
-
store[{"hashkey1"=>"hashkey2"}].should_not be_equal(
|
|
16804
|
+
store[{"hashkey1"=>"hashkey2"}] = value
|
|
16805
|
+
store[{"hashkey1"=>"hashkey2"}].should_not be_equal(value)
|
|
16330
16806
|
end
|
|
16331
16807
|
|
|
16332
16808
|
it 'guarantees that a different value is retrieved' do
|
|
16333
16809
|
value = Value.new(:objval2)
|
|
16334
|
-
store[{"hashkey3"=>"hashkey4"}] =
|
|
16335
|
-
store[{"hashkey3"=>"hashkey4"}].should_not be_equal(
|
|
16810
|
+
store[{"hashkey3"=>"hashkey4"}] = value
|
|
16811
|
+
store[{"hashkey3"=>"hashkey4"}].should_not be_equal(value)
|
|
16812
|
+
end
|
|
16813
|
+
end
|
|
16814
|
+
|
|
16815
|
+
#################### returnsame_hashkey_objectvalue ####################
|
|
16816
|
+
|
|
16817
|
+
shared_examples_for 'returnsame_hashkey_objectvalue' do
|
|
16818
|
+
it 'guarantees that the same value is retrieved' do
|
|
16819
|
+
value = Value.new(:objval1)
|
|
16820
|
+
store[{"hashkey1"=>"hashkey2"}] = value
|
|
16821
|
+
store[{"hashkey1"=>"hashkey2"}].should be_equal(value)
|
|
16822
|
+
end
|
|
16823
|
+
|
|
16824
|
+
it 'guarantees that the same value is retrieved' do
|
|
16825
|
+
value = Value.new(:objval1)
|
|
16826
|
+
store[{"hashkey3"=>"hashkey4"}] = value
|
|
16827
|
+
store[{"hashkey3"=>"hashkey4"}].should be_equal(value)
|
|
16828
|
+
end
|
|
16829
|
+
|
|
16830
|
+
it 'guarantees that the same value is retrieved' do
|
|
16831
|
+
value = Value.new(:objval2)
|
|
16832
|
+
store[{"hashkey1"=>"hashkey2"}] = value
|
|
16833
|
+
store[{"hashkey1"=>"hashkey2"}].should be_equal(value)
|
|
16834
|
+
end
|
|
16835
|
+
|
|
16836
|
+
it 'guarantees that the same value is retrieved' do
|
|
16837
|
+
value = Value.new(:objval2)
|
|
16838
|
+
store[{"hashkey3"=>"hashkey4"}] = value
|
|
16839
|
+
store[{"hashkey3"=>"hashkey4"}].should be_equal(value)
|
|
16336
16840
|
end
|
|
16337
16841
|
end
|
|
16338
16842
|
|
|
@@ -16430,9 +16934,9 @@ shared_examples_for 'expires' do
|
|
|
16430
16934
|
sleep 1
|
|
16431
16935
|
store.load('key2', :expires => 3).should == 'val2'
|
|
16432
16936
|
store['key2'].should == 'val2'
|
|
16433
|
-
sleep
|
|
16937
|
+
sleep 2
|
|
16434
16938
|
store['key2'].should == 'val2'
|
|
16435
|
-
sleep
|
|
16939
|
+
sleep 2
|
|
16436
16940
|
store['key2'].should be_nil
|
|
16437
16941
|
end
|
|
16438
16942
|
|
|
@@ -16456,9 +16960,9 @@ shared_examples_for 'expires' do
|
|
|
16456
16960
|
sleep 1
|
|
16457
16961
|
store.key?('key2', :expires => 3).should be_true
|
|
16458
16962
|
store['key2'].should == 'val2'
|
|
16459
|
-
sleep
|
|
16963
|
+
sleep 2
|
|
16460
16964
|
store['key2'].should == 'val2'
|
|
16461
|
-
sleep
|
|
16965
|
+
sleep 2
|
|
16462
16966
|
store['key2'].should be_nil
|
|
16463
16967
|
end
|
|
16464
16968
|
|
|
@@ -16482,9 +16986,9 @@ shared_examples_for 'expires' do
|
|
|
16482
16986
|
sleep 1
|
|
16483
16987
|
store.fetch('key1', nil, :expires => 3).should == 'val1'
|
|
16484
16988
|
store['key1'].should == 'val1'
|
|
16485
|
-
sleep
|
|
16989
|
+
sleep 2
|
|
16486
16990
|
store['key1'].should == 'val1'
|
|
16487
|
-
sleep
|
|
16991
|
+
sleep 2
|
|
16488
16992
|
store['key1'].should be_nil
|
|
16489
16993
|
end
|
|
16490
16994
|
|