test/test.rb in rufus-lru-1.0.1 vs test/test.rb in rufus-lru-1.0.2

- old
+ new

@@ -18,11 +18,11 @@ #end #def teardown #end - def test_lru_0 + def test_0 h = LruHash.new 3 assert_equal 0, h.size @@ -66,8 +66,20 @@ assert_equal "B", h[:b] assert_equal "A", h[:a] assert_equal "D", h[:d] assert_equal nil, h[:c] assert_equal [ :b, :a, :d ], h.ordered_keys + end + + def test_1 + + h = LruHash.new 3 + + h[1] = 10 + + h.merge!({ 2 => 20, 3 => 30, 4 => 40, 5 => 50 }) + + assert_nil h[1] + assert_equal 3, h.size end end