diff --git a/lib/tasks/tests.rake b/lib/tasks/tests.rake index 09333cb0f..f578a0d80 100644 --- a/lib/tasks/tests.rake +++ b/lib/tasks/tests.rake @@ -11,9 +11,11 @@ namespace :ci do end end -namespace :tests do - desc "Run all specs that generate fixtures for rspec or jasmine" - RSpec::Core::RakeTask.new(:generate_fixtures) do |t| - t.rspec_opts = ['--tag fixture'] +if defined?(RSpec) + namespace :tests do + desc "Run all specs that generate fixtures for rspec or jasmine" + RSpec::Core::RakeTask.new(:generate_fixtures) do |t| + t.rspec_opts = ['--tag fixture'] + end end end