require self made gem in jruby fails after update to jruby-1.7.13

前端 未结 1 581
忘了有多久
忘了有多久 2021-01-28 08:02

I used jruby-1.7.0 and testing frame work Test::Unit::TestCase. Now I have updated some gems which caused me to use MiniTest::Test for testing, so I also upgraded to jruby-1.7.1

相关标签:
1条回答
  • 2021-01-28 08:57

    I found a surprising solution to the problem. I had compiled the *.rb classes with my jruby version 1.7.0's jrubyc. This caused the tests to fail with the load error. I had to compile all ruby classes with the jrubyc version 1.7.13 where I also build the gems.

    update:

    'rake test' still does not work comming up with errors like Mocha::ExpectationError: unexpected invocation: ...

    what works is to use test options specifiying test file and test name (also with reg.exp.) like

    rake test TEST=test/test_bla_bla.rb TESTOPTS="--name=/test_should_read/ -v"

    I have the feeling the randomization with the seed parameter causes the problem. How can I influence the seed parameter?

    update:

    It looks like if there are too many tests in the test suite, MiniTest cannot handle this. In some cases I could run about 10 tests in some up to 35, using the TESTOPTS switch. I always fail if I run all tests in my test library with 'rake test'. This looks like a bug to me. Is there anybody who can help?

    0 讨论(0)
提交回复
热议问题