[rspec-users] rake spec order of running tests

Mark Wilden mark at mwilden.com
Thu Aug 21 15:25:16 EDT 2008

We ran into a situation today where running 'rake spec' on one machine
produced different results than when running on a different machine. My
reasoned hunch is that the tests were run in a different order, due to the
file-globbing producing differently ordered file lists. Because some tests
used fixtures and some didn't, that resulted in different test db contents,
depending on the order the tests were run (clearly, these tests need

I haven't really looked into this at all, for now. But it occurs to me that
if my suspicion is correct, this situation would be fixed by running tests
in alphabetical order. Presumably this would be a change to the spec Rake

Does this make any kind of sense? If so, I (or someone better suited to the
task) could look into it further. (Coincidentally, a similar situation
resulted in a contribution I made to Visual FoxPro!)

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://rubyforge.org/pipermail/rspec-users/attachments/20080821/78c8583c/attachment.html>

More information about the rspec-users mailing list