Skip to content
This repository has been archived by the owner on Apr 17, 2018. It is now read-only.

Commit

Permalink
Make db:test:prepare a noop (at least for now)
Browse files Browse the repository at this point in the history
Previously, running rake spec would always

  (1) create
  (2) auto_migrate!
  (3) seed

the database because db:test:prepare was coded to
do that. Then the spec_helper would have contained
another auto_migrate! command typically.

The proper behavior would probably be to at least
check for pending migrations, but this is not yet
implemented.

Making db:test:prepare a noop for now seems like a
reasonable way, because it gives full control over
auto_migrate! / auto_upgrade! to the spec_helper.rb
and this is how it's typically handled with DM.
  • Loading branch information
snusnu committed Sep 13, 2010
1 parent ab88c7d commit 376cb66
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions lib/dm-rails/railties/database.rake
Expand Up @@ -6,10 +6,6 @@ namespace :db do
desc 'Create the database, load the schema, and initialize with the seed data'
task :setup => [ 'db:create', 'db:automigrate', 'db:seed' ]

namespace :test do
task :prepare => ['db:setup']
end

namespace :create do
desc 'Create all the local databases defined in config/database.yml'
task :all => :environment do
Expand Down

0 comments on commit 376cb66

Please sign in to comment.