spec/support/macros/database_macros.rb in partisan-0.0.1 vs spec/support/macros/database_macros.rb in partisan-0.1

- old
+ new

@@ -10,11 +10,11 @@ # Create a new instance of it and execute its `up` method klass.new.up end def self.database_file - @database_file || File.join(File.dirname(__FILE__), 'test.db') + @database_file || File.expand_path('../test.db', __FILE__) end def setup_database # Make sure the test database file is gone cleanup_database @@ -31,9 +31,9 @@ FileUtils.rm(DatabaseMacros.database_file) if File.exists?(DatabaseMacros.database_file) end # Run the built-in migration def run_default_migration - load File.join(File.dirname(__FILE__), '../../../lib/generators/partisan/templates/migration.rb') + load File.expand_path('../../../../lib/generators/partisan/templates/migration.rb', __FILE__) AddFollowsMigration.new.up end end