[#4184] Starting on the budget data migration.

This commit is contained in:
Eric Davis
2010-07-13 14:35:23 -07:00
parent d8196842ff
commit 30172b4be1
3 changed files with 97 additions and 0 deletions
@@ -0,0 +1,24 @@
require 'test_helper'
class BudgetPluginMigrationTest < ActionController::IntegrationTest
def setup
configure_overhead_plugin
end
def load_test_fixture
YAML.load(File.read(File.expand_path(File.dirname(__FILE__)) + "/../fixtures/budget_plugin_migration/budget.yml"))
end
context "migrate" do
should "load a YAML dump of the old budget data" do
@data = load_test_fixture
RedmineContracts::BudgetPluginMigration.migrate(@data)
assert RedmineContracts::BudgetPluginMigration.data
end
should "create a new Deliverable for each old Deliverable"
should "create a new Contract for each project that had an old deliverable"
end
end