private method `run' called #36

Closed
madebydna opened this Issue Jul 9, 2012 · 3 comments

Projects

None yet

2 participants

@madebydna

Hi,

Since upgrading to test-unit 2.5.1, I'm getting the following error when running my tests with guard:

/Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit/testsuite.rb:117:in `run_test': private method `run' called for #<AnnotationScoreTest:0x109f96140> (NoMethodError)
    from /Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit/testsuite.rb:53:in `run'
    from /Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit/testsuite.rb:117:in `run_test'
    from /Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit/testsuite.rb:53:in `run'
    from /Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit/ui/testrunnermediator.rb:93:in `run_suite'
    from /Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit/ui/testrunnermediator.rb:43:in `run'
    from /Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit/ui/testrunnermediator.rb:82:in `with_listener'
    from /Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit/ui/testrunnermediator.rb:39:in `run'
    from /Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit/ui/testrunner.rb:40:in `start_mediator'
    from /Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit/ui/testrunner.rb:25:in `start'
    from /Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit/ui/testrunnerutilities.rb:24:in `run'
    from /Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit/autorunner.rb:378:in `run'
    from /Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit/autorunner.rb:434:in `change_work_directory'
    from /Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit/autorunner.rb:377:in `run'
    from /Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit/autorunner.rb:58:in `run'
    from /Users/asingh/.rvm/gems/ruby-1.8.7-p358@genegrabber/gems/test-unit-2.5.1/lib/test/unit.rb:330

Doing a tiny bit of digging, I found that #<AnnotationScoreTest:0x109f96140> is actually an instance of Test::Unit::TestSuite for which run is indeed a private method.

My stack:

  • ruby-1.8.7-p358
  • rails 3.2.6
  • test-unit 2.5.1
  • test-unit-rails 1.0.2
  • mocha 0.12.0
  • guard 1.2.3
  • guard-test 0.5.0
  • machinist 2.0

Thanks!

@kou
test-unit member

It seems that freerange/mocha#89 is the same as your problem and fix for your problem. :-)

@madebydna

Thanks for your quick reply. I will keep an eye on the mocha issue to see how it gets resolved.

@kou
test-unit member

Mochar 0.12.6 had been released. You can use test-unit 2.5.2 with it. :-)

@kou kou closed this Sep 28, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment