diff options
Diffstat (limited to 'test')
-rw-r--r-- | test/psych/test_hash.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/psych/test_hash.rb b/test/psych/test_hash.rb index e658984f48..e2a312901a 100644 --- a/test/psych/test_hash.rb +++ b/test/psych/test_hash.rb @@ -23,6 +23,13 @@ module Psych @hash = { :a => 'b' } end + def test_referenced_hash_with_ivar + a = [1,2,3,4,5] + t1 = [HashWithCustomInit.new(a)] + t1 << t1.first + assert_cycle t1 + end + def test_custom_initialized a = [1,2,3,4,5] t1 = HashWithCustomInit.new(a) |