From 1954eec80d7b9111920aa758b4c85405f907f671 Mon Sep 17 00:00:00 2001 From: why Date: Fri, 12 Dec 2003 18:08:58 +0000 Subject: * lib/yaml/rubytypes.rb: anonymous struct fix. [ruby-core:01946] * test/yaml/test_yaml.rb: add test. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@5178 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- test/yaml/test_yaml.rb | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'test') diff --git a/test/yaml/test_yaml.rb b/test/yaml/test_yaml.rb index cfb6407c2..35bb7c5f7 100644 --- a/test/yaml/test_yaml.rb +++ b/test/yaml/test_yaml.rb @@ -4,6 +4,11 @@ require 'test/unit' require 'yaml' +# [ruby-core:01946] +module YAML_Tests + StructTest = Struct::new( :c ) +end + class YAML_Unit_Tests < Test::Unit::TestCase # # Convert between YAML and the object to verify correct parsing and @@ -1058,6 +1063,12 @@ EOY isbn: None EOY ) + + assert_to_yaml( YAML_Tests::StructTest.new( 123 ), <