Permalink
Browse files

Synchronize `rspec spec` and `rake spec` output

By removing the `rake spec` short circuiting the output between
invocation methods matches more closely.

Fixes rspec/rspec-core#812
  • Loading branch information...
sorentwo committed Mar 20, 2013
1 parent 6174790 commit 6a0191de945f3d9d33f1e342afe9ddada0e99dd2
Showing with 8 additions and 16 deletions.
  1. +8 −16 lib/rspec/core/rake_task.rb
@@ -137,24 +137,16 @@ def setup_ivars(args)
@pattern = './spec{,/*/**}/*_spec.rb'
end
- def has_files?
- empty = files_to_run.empty?
- puts "No examples matching #{pattern} could be found" if empty
- not empty
- end
-
def run_task(verbose)
- files = has_files?
- if files
- command = spec_command
- begin
- puts command if verbose
- success = system(command)
- rescue
- puts failure_message if failure_message
- end
- raise("#{command} failed") if fail_on_error unless success
+ command = spec_command
+
+ begin
+ puts command if verbose
+ success = system(command)
+ rescue
+ puts failure_message if failure_message
end
+ raise("#{command} failed") if fail_on_error unless success
end
private

0 comments on commit 6a0191d

Please sign in to comment.