test/test_double.rb in double-0.1.0 vs test/test_double.rb in double-0.1.1
- old
+ new
@@ -13,12 +13,13 @@
Foo.class_eval 'self.double = Bar'
end
Foo.extend Double
Foo.class_eval 'self.double = Bar'
- assert_raise NameError do
+ e = assert_raise NameError do
Foo.double.baz
end
+ assert_nil e.message.match /Kernel::Bar/
Kernel.const_set :Bar, Module.new
assert_raise NoMethodError do
Bar.baz
end