summaryrefslogtreecommitdiffhomepage
path: root/test/t/hash.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/t/hash.rb')
-rw-r--r--test/t/hash.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/t/hash.rb b/test/t/hash.rb
index 3196cc97a..c8d7a70ef 100644
--- a/test/t/hash.rb
+++ b/test/t/hash.rb
@@ -239,6 +239,10 @@ assert('Hash#replace', '15.2.13.4.23') do
a = Hash.new{|h,x| x}
b.replace(a)
assert_equal(127, b[127])
+
+ assert_raise(TypeError) do
+ { 'abc_key' => 'abc_value' }.replace "a"
+ end
end
assert('Hash#shift', '15.2.13.4.24') do