From da7976235fbc2986925969646071bebe3702e49f Mon Sep 17 00:00:00 2001 From: eregon Date: Thu, 21 Feb 2019 15:38:59 +0000 Subject: Update to ruby/spec@7a16e01 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@67112 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- spec/ruby/library/yaml/fixtures/example_class.rb | 8 +++++--- spec/ruby/library/yaml/to_yaml_spec.rb | 3 +-- 2 files changed, 6 insertions(+), 5 deletions(-) (limited to 'spec/ruby/library/yaml') diff --git a/spec/ruby/library/yaml/fixtures/example_class.rb b/spec/ruby/library/yaml/fixtures/example_class.rb index 751435a305..8259870799 100644 --- a/spec/ruby/library/yaml/fixtures/example_class.rb +++ b/spec/ruby/library/yaml/fixtures/example_class.rb @@ -1,5 +1,7 @@ -class FooBar - def initialize(name) - @name = name +module YAMLSpecs + class Example + def initialize(name) + @name = name + end end end diff --git a/spec/ruby/library/yaml/to_yaml_spec.rb b/spec/ruby/library/yaml/to_yaml_spec.rb index 9713657a26..d73ae9bee4 100644 --- a/spec/ruby/library/yaml/to_yaml_spec.rb +++ b/spec/ruby/library/yaml/to_yaml_spec.rb @@ -13,8 +13,7 @@ describe "Object#to_yaml" do end it "returns the YAML representation of a Class object" do - FooBar.new("baz").to_yaml.should match_yaml("--- !ruby/object:FooBar\nname: baz\n") - + YAMLSpecs::Example.new("baz").to_yaml.should match_yaml("--- !ruby/object:YAMLSpecs::Example\nname: baz\n") end it "returns the YAML representation of a Date object" do -- cgit v1.2.3