Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

assuming a default task exists is bad when somehow it's nil, then pre…

…requisities blows up
  • Loading branch information...
commit c136b99c3f066f35b10e28d88a82c6e926ca76a1 1 parent 96222d6
@jackdempsey authored
Showing with 3 additions and 1 deletion.
  1. +3 −1 lib/rspec/rails/tasks/rspec.rake
View
4 lib/rspec/rails/tasks/rspec.rake
@@ -1,6 +1,8 @@
require 'rspec/core'
require 'rspec/core/rake_task'
-Rake.application.instance_variable_get('@tasks')['default'].prerequisites.delete('test')
+if default = Rake.application.instance_variable_get('@tasks')['default']
+ default.prerequisites.delete('test')
+end
spec_prereq = Rails.configuration.generators.options[:rails][:orm] == :active_record ? "db:test:prepare" : :noop
task :noop do; end
Please sign in to comment.
Something went wrong with that request. Please try again.