summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/visitors/test_to_ruby.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/visitors/test_to_ruby.rb b/test/visitors/test_to_ruby.rb
index db748ca..c295caf 100644
--- a/test/visitors/test_to_ruby.rb
+++ b/test/visitors/test_to_ruby.rb
@@ -28,6 +28,12 @@ module Psych
mapping.children << Nodes::Scalar.new('bar')
assert_equal({'foo' => 'bar'}, mapping.to_ruby)
end
+
+ def test_document
+ doc = Nodes::Document.new
+ doc.children << Nodes::Scalar.new('foo')
+ assert_equal 'foo', doc.to_ruby
+ end
end
end
end