public
Description: Ruby on Rails
Homepage: http://rubyonrails.org
Clone URL: git://github.com/rails/rails.git
Don't dump schema for every test run, just when migrations are run
jeremy (author)
Mon Jun 16 03:47:15 -0700 2008
commit  8e74a434b8f13bd1697ad556c9fd1ef0217e594e
tree    4d7f3aa25525b04b13e0fd7263c0281c1c77c4fe
parent  899d63b997094f066ffd49a3e58d29c07143999d
...
337
338
339
340
341
 
 
342
343
 
344
345
346
...
337
338
339
 
 
340
341
342
 
343
344
345
346
0
@@ -337,10 +337,10 @@ namespace :db do
0
       end
0
     end
0
 
0
-    desc 'Prepare the test database and load the schema'
0
-    task :prepare => %w(environment db:abort_if_pending_migrations) do
0
+    desc 'Check for pending migrations and load the test schema'
0
+    task :prepare => 'db:abort_if_pending_migrations' do
0
       if defined?(ActiveRecord) && !ActiveRecord::Base.configurations.blank?
0
-        Rake::Task[{ :sql  => "db:test:clone_structure", :ruby => "db:test:clone" }[ActiveRecord::Base.schema_format]].invoke
0
+        Rake::Task[{ :sql  => "db:test:clone_structure", :ruby => "db:schema:load" }[ActiveRecord::Base.schema_format]].invoke
0
       end
0
     end
0
   end

Comments