mirror of
https://github.com/meineerde/redmine.git
synced 2026-02-01 03:57:15 +00:00
Fix "ArgumentError: wrong number of arguments (given 1, expected 2) on Redmine::PluginTest#test_migrate_redmine_plugin" (#29914, #32939).
Patch by Pavel Rosický. git-svn-id: http://svn.redmine.org/redmine/trunk@20888 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
f30c91341a
commit
f223f707da
@ -539,7 +539,7 @@ module Redmine
|
||||
else
|
||||
migrations
|
||||
end
|
||||
Migrator.new(:up, selected_migrations, target_version).migrate
|
||||
Migrator.new(:up, selected_migrations, schema_migration, target_version).migrate
|
||||
end
|
||||
|
||||
def down(target_version = nil)
|
||||
@ -549,15 +549,15 @@ module Redmine
|
||||
else
|
||||
migrations
|
||||
end
|
||||
Migrator.new(:down, selected_migrations, target_version).migrate
|
||||
Migrator.new(:down, selected_migrations, schema_migration, target_version).migrate
|
||||
end
|
||||
|
||||
def run(direction, target_version)
|
||||
Migrator.new(direction, migrations, target_version).run
|
||||
Migrator.new(direction, migrations, schema_migration, target_version).run
|
||||
end
|
||||
|
||||
def open
|
||||
Migrator.new(:up, migrations, nil)
|
||||
Migrator.new(:up, migrations, schema_migration)
|
||||
end
|
||||
end
|
||||
|
||||
@ -571,7 +571,7 @@ module Redmine
|
||||
self.current_plugin = plugin
|
||||
return if current_version(plugin) == version
|
||||
|
||||
MigrationContext.new(plugin.migration_directory).migrate(version)
|
||||
MigrationContext.new(plugin.migration_directory, ::ActiveRecord::Base.connection.schema_migration).migrate(version)
|
||||
end
|
||||
|
||||
def get_all_versions(plugin = current_plugin)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user