Weird RSpec practice.

Posted by labria on June 25, 2009

I recently found myself doing a wierd thing. While writing specs i add this spec to the end of the file:

 
it "should fail" do
  raise "foo"
end
 

The reason to do it? Simple: every time i have all the specs passing in the current file, autospec begins running all the specs in my project, breaking my red-green cycle for about 30 seconds. Adding a failing spec prevents it from doing it, and speeds up my work.

Am I doing something wrong?