[rspec-users] Rspec on rails with out database?

David Chelimsky dchelimsky at gmail.com
Fri Jul 27 17:57:03 EDT 2007


On 7/27/07, David Chelimsky <dchelimsky at gmail.com> wrote:
> On 7/27/07, David Chelimsky <dchelimsky at gmail.com> wrote:
> > On 7/24/07, Eric Pugh <epugh at opensourceconnections.com> wrote:
> > > Hi all,
> > >
> > > I am trying to use rspec_on_rails in a Rails app that doesn't have a
> > > database.  so far I have just been faking it out by dumping in a
> > > sqlite3 database just to make Rails happy.
> >
> > Try deleting config/database.yml (or renaming it to something else)
> > and then running:
> >
> > rake spec
> >
> > That should do it.
>
> I take it back. It doesn't work. There is an open RFE on making this
> work - perhaps it's time to address it.
>

Ah - this worked using Rails 1.2.3 and RSpec's trunk. In config/environments.rb:

Rails::Initializer.run do |config|
  config.frameworks -= [ :active_record ]
end

Cheers,
David


More information about the rspec-users mailing list