Cucumber.yml was found, but could not be parsed.

07 Apr 2010

Cucumber suddenly stopped working today with this error message:

  cucumber.yml was found, but could not be parsed. 
  Please refer to cucumber's documentation on correct profile usage. 

I hadn't changed that file and I couldn't understand what could have caused it to stop working. To troubleshoot I tried parsing the file manually:

  $ script/console
  >> e = ERB.new(File.read('config/cucumber.yml'))
  >> pp e.result
  "\ndefault: --format pretty features/search.feature:14\nted/features/search.feature:16\n --format rerun --out rerun.txt --strict --tags ~@wip\nwip: --tags @wip:3 --wip features\n"

See that extra stuff? That is in the rerun.txt - so I removed it and now I'm back in business.

  $ rm rerun.txt