summaryrefslogtreecommitdiff
path: root/test/ruby/test_module.rb
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-10-09 08:41:13 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2013-10-09 08:41:13 +0000
commit289d6bb30f4c2fffa2437436030c889f10522e72 (patch)
treeb15592f8711911f5fa1be329bb20dd7ce6d4aed8 /test/ruby/test_module.rb
parenta28de81aec2cb6af9199891f2fba17efc6f1ebc8 (diff)
test: use assert_raise
* test/ruby, test/-ext-: use assert_raise instead of assert_raises. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@43211 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/ruby/test_module.rb')
-rw-r--r--test/ruby/test_module.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/ruby/test_module.rb b/test/ruby/test_module.rb
index 144b75d9f7..ddaf6777b4 100644
--- a/test/ruby/test_module.rb
+++ b/test/ruby/test_module.rb
@@ -248,7 +248,7 @@ class TestModule < Test::Unit::TestCase
":",
["String::", "[Bug #7573]"],
].each do |name, msg|
- e = assert_raises(NameError, "#{msg}#{': ' if msg}wrong constant name #{name.dump}") {
+ e = assert_raise(NameError, "#{msg}#{': ' if msg}wrong constant name #{name.dump}") {
Object.const_get name
}
assert_equal("wrong constant name %s" % name, e.message)
@@ -296,7 +296,7 @@ class TestModule < Test::Unit::TestCase
end
def test_nested_bad_class
- assert_raises(TypeError) do
+ assert_raise(TypeError) do
self.class.const_get([User, 'USER', 'Foo'].join('::'))
end
end
@@ -1656,7 +1656,7 @@ class TestModule < Test::Unit::TestCase
@@foo
$foo
].each do |name|
- assert_raises(NameError) do
+ assert_raise(NameError) do
Module.new { attr_accessor name.to_sym }
end
end