[rspec-users] Autotest will run features, but not specs

Brennon Bortz brennon at brennonbortz.com
Fri Aug 27 09:48:48 EDT 2010

On 27 Aug 2010, at 14:44, David Chelimsky wrote:

> On Aug 27, 2010, at 8:37 AM, Brennon Bortz wrote:
>> On 27 Aug 2010, at 14:29, Brennon Bortz wrote:
>>> On 27 Aug 2010, at 14:06, David Chelimsky wrote:
>>>> On Aug 27, 2010, at 6:47 AM, Brennon Bortz wrote:
>>>>> Not sure what I must have bumped, but autotest won't run any specs--only features.  No errors are given on startup.  I've taken "export AUTOFEATURE=true" out of my ./bashrc file--now I just get a blank screen when running autotest.  Adding "export RSPEC=true" to .bashrc doesn't change anything either.
>>>> 1. Get rid of 'Autotest.add_discovery { "rails" }' from ./autotest/discover.rb.
>>>> 2. Add autotest-rails to the Gemfile.
>>>> If any of the gems listed in the Gemfile have :path or :git options, you need to run "bundle exec autotest".
>>>> HTH,
>>>> DavidStrange...that does work, but now autotest seems caught in an infinite loop.  When I run autospec, the specs run, then the features, then the features again...and again...and again...and so on.  If I run autotest as follows: "AUTOFEATURE=false autotest", I don't have the problem.  Any other ideas?
>> And now (I haven't touched anything...seriously!), even "AUTOFEATURE=false autotest" gives me an endless loop of spec tests...
> (I moved your posts to the bottom so we can read them in order. Please post at the bottom or inline.)
> I've seen this happen when files are generated during a spec run. What's in spec/spec.opts and cucumber.yml?

No spec.opts file, and just the default cucumber.yml file (I believe):

rerun = File.file?('rerun.txt') ? IO.read('rerun.txt') : ""
rerun_opts = rerun.to_s.strip.empty? ? "--format #{ENV['CUCUMBER_FORMAT'] || 'progress'} features" : "--format #{ENV['CUCUMBER_FORMAT'] || 'pretty'} #{rerun}"
std_opts = "--format #{ENV['CUCUMBER_FORMAT'] || 'progress'} --strict --tags ~@wip"
default: <%= std_opts %> features
wip: --tags @wip:3 --wip features
rerun: <%= rerun_opts %> --format rerun --out rerun.txt --strict --tags ~@wip

More information about the rspec-users mailing list