提交 e1134806 编写于 作者: J John Firebaugh

Don't test language-level exception messages

Ruby implementations should be free to produce exception
messages that are not identical to MRI. For example,
Rubinius produces 'Expected an even number, got 5'.
上级 1fab518c
......@@ -226,12 +226,8 @@ def test_alternate_initialization_with_array
end
def test_alternate_initialization_raises_exception_on_odd_length_args
begin
assert_raises ArgumentError do
ActiveSupport::OrderedHash[1,2,3,4,5]
flunk "Hash::[] should have raised an exception on initialization " +
"with an odd number of parameters"
rescue ArgumentError => e
assert_equal "odd number of arguments for Hash", e.message
end
end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册