summaryrefslogtreecommitdiff
path: root/test/psych/test_psych.rb
diff options
context:
space:
mode:
authortenderlove <tenderlove@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-04-09 16:09:55 +0000
committertenderlove <tenderlove@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-04-09 16:09:55 +0000
commit052f204dcbb3d02509a47e8bd559a444a3f81160 (patch)
tree7f0b58cad34ab2c51edbb33abea5c817e7c6cc51 /test/psych/test_psych.rb
parent5869de449fe535321a1f43d3ca59c22cdf610e9e (diff)
* ext/psych/parser.c: parse raises a TypeError when nil is passed in.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27278 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/psych/test_psych.rb')
-rw-r--r--test/psych/test_psych.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/psych/test_psych.rb b/test/psych/test_psych.rb
index 22baa14..91c67b1 100644
--- a/test/psych/test_psych.rb
+++ b/test/psych/test_psych.rb
@@ -4,6 +4,12 @@ require 'stringio'
require 'tempfile'
class TestPsych < Psych::TestCase
+ def test_load_argument_error
+ assert_raises(TypeError) do
+ Psych.load nil
+ end
+ end
+
def test_dump_stream
things = [22, "foo \n", {}]
stream = Psych.dump_stream(*things)