The following output appears after running some rake tasks:
Loaded suite /usr/bin/rake
Started
Finished in 0.00042 seconds.
0 tests, 0 assertions, 0 failures, 0 errors
This output is not useful or necessary for tasks not related to testing. I'd like to prevent it from appearing. I would assume it stems from requiring a certain file or including a certain module.
Updated: It appears that I was wrong and this does come up during some of the tasks built into Rails. Here is the output of fixtures being loaded with --trace
.
$ rake db:fixtures:load --trace
** Invoke db:fixtures:load (first_time)
** Invoke environment (first_time)
** Execute environment
** Execute db:fixtures:load
Loaded suite /usr/bin/rake
Started
Finished in 0.000255 seconds.
0 tests, 0 assertions, 0 failures, 0 errors
Solution can be found here:
http://github.com/thoughtbot/shoulda/issues/#issue/59
Basically don't require the shoulda gem unless it's the test environment (where test/unit would already be required).
First check the test pattern for your Rake::TestTask
. Should be something like 'test/**/*_test.rb'
.
For whatever reason, Test::Unit is trying to find tests in the /usr/bin/rake
executable, which probably means you've got a bogus pattern somewhere.
Anytime you have problems like this, you want to run rake
with --trace
to see what tasks and task dependencies are being run, and in which order. If updating the pattern doesn't work, please copy the output of a full run with --trace
switched on into your question.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With