Why won't my features specs run in RSpec?

rspec, ruby-on-rails

Solution

Based on your feedback to the comments above, the issue is one of file naming. I've definitely been burned by that before too. By default Rspec will go through the files looking for ones ending with `_spec.rb`, this default behaviour is overridden if you specify the folder manually.

Problem

In my Rails 4 app, I'm using Rspec for testing. My directory structure is ``` spec -- controllers -- factories -- features -- spec_helper.rb -- support ``` When I run `rspec spec`, it runs my tests in `controllers`, but not in `features`. I can specify `rspec spec/features` and they'll run, but I want to be able to run all tests under `spec` at once. My guess is it's not looking in `features` because of a configuration setting, but I don't know where this is. I've tried different incantations of starting rspec but haven't had any luck.

Original source