jstorimer/spin — pull request #5 by mathieul (2011-11-01 23:04:08+00:00)
Title: Allow to force the test framework and the application init file on the command line

Thanks for a great tool that already speeds up our TDD workflow!

I wanted to use it for 2 different apps, one using rails 2.3 and another one using 3.0. Also we're using RSpec inside our Cucumber scenarios, but are using Test unit for all other tests.

So I added an option to allow to force the test framework:

**$ spin serve -t test**

And another one to specify the application init file (config/application.rb for rails 3, config/environment.rb for rails 2 for instance):

**$ spin serve -i config/environment.rb**

As part of those modifications I refactored the code to structure it into classes (personal preference, makes it easier to extend) and am using OptParser standard library to parse the command line.

Thanks again, hopefully you'll find this pull request useful.