* test: assert_raises has been deprecated since a long time ago.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19536 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2008-09-24 17:44:39 +00:00
parent 48fdf59dcf
commit 00b4a3f9c4
59 changed files with 284 additions and 284 deletions

View file

@ -32,7 +32,7 @@ module TestOptionParser::ReqArg
end
def test_short
assert_raises(OptionParser::MissingArgument) {@opt.parse!(%w"-x")}
assert_raise(OptionParser::MissingArgument) {@opt.parse!(%w"-x")}
assert_equal(%w"", no_error {@opt.parse!(%w"-x foo")})
assert_equal("foo", @flag)
assert_equal(%w"", no_error {@opt.parse!(%w"-xbar")})
@ -42,7 +42,7 @@ module TestOptionParser::ReqArg
end
def test_abbrev
assert_raises(OptionParser::MissingArgument) {@opt.parse!(%w"-o")}
assert_raise(OptionParser::MissingArgument) {@opt.parse!(%w"-o")}
assert_equal(%w"", no_error {@opt.parse!(%w"-o foo")})
assert_equal("foo", @flag)
assert_equal(%w"", no_error {@opt.parse!(%w"-obar")})
@ -52,7 +52,7 @@ module TestOptionParser::ReqArg
end
def test_long
assert_raises(OptionParser::MissingArgument) {@opt.parse!(%w"--opt")}
assert_raise(OptionParser::MissingArgument) {@opt.parse!(%w"--opt")}
assert_equal(%w"", no_error {@opt.parse!(%w"--opt foo")})
assert_equal("foo", @flag)
assert_equal(%w"foo", no_error {@opt.parse!(%w"--opt= foo")})