Skip to content
New issue

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

Rails-perftest not working with Minitest 5.11.3 #43

Closed
rbclark opened this issue Mar 14, 2018 · 3 comments · Fixed by #44
Closed

Rails-perftest not working with Minitest 5.11.3 #43

rbclark opened this issue Mar 14, 2018 · 3 comments · Fixed by #44

Comments

@rbclark
Copy link

rbclark commented Mar 14, 2018

There is currently an issue where minitest 5.11.3 will cause this gem to throw a

minitest.rb:961:in `run_one_method': TestName#run _must_ return a Result (RuntimeError)

This issue is due to a change in minitest which causes the run method to be expected to return a Result instead of just self. The easiest way to fix this is to change the previously linked line in minitest from self to ::Minitest::Result.from self however that will break compatibility with Minitest 4 and < 5.11.

Would the preferred way to fix this be to create a new module called Minitest511AndGreater which handles this properly and then check the version, or is there a better way that I am missing?

@pioz
Copy link

pioz commented May 7, 2018

When are you going to release the gem with this fix? (I really need it :D)

@haggen
Copy link

haggen commented May 31, 2018

Yea a fix for this and the rubyprof-0.17 bug would be really great!

peff added a commit to git/git-scm.com that referenced this issue Dec 12, 2020
I can't get this to run on modern ruby/rails. The error looks like this:

  .../gems/minitest-5.14.2/lib/minitest.rb:1030:in `run_one_method': BrowsingDocTest#run _must_ return a Result (RuntimeError)

Looks like an incompatibility between minitest and rails-perftest,
according to:

  rails/rails-perftest#43

There's even a patch which was merged:

  rails/rails-perftest#44

but it looks like never released. I'm not sure I care enough about this
test to wrestle with it further. Comparing perf between versions might
be interesting, but fundamentally we can't _fail_ this in the automated
testing without some kind of baseline. So I don't think it brings much
value to the regression tests.
@aesyondu
Copy link

Anyone know a workaround for this, since it hasn't been released yet? I have [email protected] with error #run _must_ return a Result (RuntimeError)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants