summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/ruby/test_string.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/ruby/test_string.rb b/test/ruby/test_string.rb
index 06a92c5957..1387feccf5 100644
--- a/test/ruby/test_string.rb
+++ b/test/ruby/test_string.rb
@@ -2243,6 +2243,12 @@ class TestString < Test::Unit::TestCase
})
end
end
+
+ def test_frozen_strings_are_deduplicated
+ a = "hello"f
+ b = "hello"f
+ assert_equal a.object_id, b.object_id
+ end
end
class TestString2 < TestString