зеркало из https://github.com/github/ruby.git
remove warning & support multi-run test for test/psych/visitors/test_to_ruby.rb (#2881)
This commit is contained in:
Родитель
b64b0f3433
Коммит
38ed8cbb5f
|
@ -24,6 +24,7 @@ module Psych
|
|||
end
|
||||
|
||||
def test_legacy_struct
|
||||
Struct.send(:remove_const, AWESOME) if Struct.const_defined?(:AWESOME)
|
||||
foo = Struct.new('AWESOME', :bar)
|
||||
assert_equal foo.new('baz'), Psych.load(<<-eoyml)
|
||||
!ruby/struct:AWESOME
|
||||
|
|
Загрузка…
Ссылка в новой задаче