We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
headius
Learn more about funding links in repositories.
Report abuse
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Example
class TestBase64 end klass = TestBase64 klass.instance_eval do def exclude(name, reason) puts "excluding #{name}" end end klass.class_eval 'exclude :test_decode64, "needs investigation"'
Expected
ruby exclude.rb excluding test_decode64
Actual
~/Documents/jruby-mine/bin/jruby -X+T exclude.rb (eval):1:in `method_missing': undefined method `exclude' for TestBase64:Class (NoMethodError) from (eval):1:in `<main>' from exclude.rb:9:in `<main>'
The text was updated successfully, but these errors were encountered:
Known issue, it is very difficult to find the proper class to define in this kind of context. Workaround: use def klass.exclude(name, reason) here.
def klass.exclude(name, reason)
Sorry, something went wrong.
I'm using the workaround locally but won't be able to make the change to the minitest/unit.rb
I could potentially ask to make the change in ruby/ruby.
I committed a workaround in ff7a1d0. I'll close this as we have specs to remind ourselves we don't do well on instance_eval on modules yet.
No branches or pull requests
Example
Expected
Actual
The text was updated successfully, but these errors were encountered: