Skip to content

Instantly share code, notes, and snippets.

@sorah
Created March 18, 2014 13:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sorah/9619956 to your computer and use it in GitHub Desktop.
Save sorah/9619956 to your computer and use it in GitHub Desktop.
diff --git a/test/ruby/test_method.rb b/test/ruby/test_method.rb
index 2e3c2ae..f478e11 100644
--- a/test/ruby/test_method.rb
+++ b/test/ruby/test_method.rb
@@ -660,6 +660,7 @@ class TestMethod < Test::Unit::TestCase
assert_equal(__dir__, eval("__dir__", binding), bug8436)
bug8662 = '[ruby-core:56099] [Bug #8662]'
assert_equal("arbitrary", eval("__dir__", binding, "arbitrary/file.rb"), bug8662)
+ assert_equal("arbitrary", Object.new.instance_eval("__dir__", "arbitrary/file.rb"), bug8662)
end
def test_alias_owner
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment