[rspec-users] is there a way to create spec tests (including directories) for an existing set of models/controllers?>>
Scott Taylor
mailing_lists at railsnewbie.com
Fri Sep 5 02:28:55 EDT 2008
On Sep 5, 2008, at 1:57 AM, Greg Hauptmann wrote:
> Hi,
>
> is there a way to create spec tests (including directories) for an
> existing set of models/controllers? (i.e. as opposed to the generate
> options that rspec provides when you are creating models/controllers
> etc to start with)
No, I don't think there is any code to do that, explicitly, but I'm
sure you could adapt it to do that:
Write a script to poll the directories for the files, run humanize on
it, call the generator for each one of those. It will prompt you to
overwrite the files. Say "no".
Scott
More information about the rspec-users
mailing list