diff options
author | tenderlove <tenderlove@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-04-27 20:19:16 +0000 |
---|---|---|
committer | tenderlove <tenderlove@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-04-27 20:19:16 +0000 |
commit | ad3c1061a78f6efe0ee3584d92b3df448da9891f (patch) | |
tree | 1db26424549eb7e3c7eacb583275dbb89fecf7cc /test/psych/test_deprecated.rb | |
parent | 4d4038f575d50e564d9b26141889fb2cc248e6de (diff) | |
download | ruby-ad3c1061a78f6efe0ee3584d92b3df448da9891f.tar.gz |
* ext/psych/lib/psych/deprecated.rb: adding deprecated "read_type_class"
method
* test/psych/test_deprecated.rb: ditto
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27518 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/psych/test_deprecated.rb')
-rw-r--r-- | test/psych/test_deprecated.rb | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/test/psych/test_deprecated.rb b/test/psych/test_deprecated.rb index 6db7238b0c..2312600ac8 100644 --- a/test/psych/test_deprecated.rb +++ b/test/psych/test_deprecated.rb @@ -187,5 +187,17 @@ module Psych assert_equal Psych, Psych.tagurize(Psych) assert_equal 'tag:yaml.org,2002:foo', Psych.tagurize('foo') end + + def test_read_type_class + things = Psych.read_type_class 'tag:yaml.org,2002:int:Psych::TestDeprecated::QuickEmitter', Object + assert_equal 'int', things.first + assert_equal Psych::TestDeprecated::QuickEmitter, things.last + end + + def test_read_type_class_no_class + things = Psych.read_type_class 'tag:yaml.org,2002:int', Object + assert_equal 'int', things.first + assert_equal Object, things.last + end end end |