1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
ruby--ruby/test/psych/test_class.rb
tenderlove c641e4b23e * ext/psych/lib/psych/visitors/to_ruby.rb: Ruby classes can be loaded
from YAML files.
* ext/psych/lib/psych/visitors/yaml_tree.rb: Ruby classes can be
  dumped to YAML files.
* test/psych/test_class.rb: corresponding test.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31958 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2011-06-09 00:06:29 +00:00

19 lines
309 B
Ruby

require 'psych/helper'
module Psych
class TestClass < TestCase
def test_cycle_anonymous_class
assert_raises(::TypeError) do
assert_cycle(Class.new)
end
end
def test_cycle
assert_cycle(TestClass)
end
def test_dump
Psych.dump TestClass
end
end
end