Reputation: 869
I'm doing the RoR Tutorial from Michael Hartl. I am just starting to write some tests, and when I run:
bundle exec rspec spec\requests\static_pages_spec.rb
I get no output at all:
C:\Wamp\www\demo_app>bundle exec rspec spec\requests\static_pages_spec.rb
C:\Wamp\www\demo_app>
I've looked around for an answer, I tried changing the version of rspec I'm using to different versions and doing bundle install over again, but I just don't get any output at all from tests that should be failing.
Any ideas what this is about?
Edit: This is what's in my .rspec file:
--color
And this is my Gemfile:
source 'https://rubygems.org'
gem 'rails', '3.2.9'
group :development, :test do
gem 'sqlite3', '1.3.5'
gem 'rspec-rails', '2.11.0'
end
group :assets do
gem 'sass-rails', '~> 3.2.3'
gem 'coffee-rails', '~> 3.2.1'
gem 'uglifier', '>= 1.0.3'
end
gem 'jquery-rails', '2.0.2'
group :test do
gem 'capybara', '1.1.2'
end
group :production do
gem 'pg', '0.12.2'
end
Upvotes: 0
Views: 296
Reputation: 869
It works when I run:
rake spec
Instead of:
bundle exec rspec spec\requests\static_pages_spec.rb
Upvotes: 1
Reputation: 5398
Make sure you added rspec-rails
to both :development
and :test
environment, as in the example in Chapter 3 of the tutorial:
group :development, :test do
gem 'rspec-rails', '2.11.0'
end
Upvotes: 0