From: Chris Yeoh Date: Wed, 13 Mar 2013 01:53:53 +0000 (+1030) Subject: Fix _migrate_up in test_migrations X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=d4a3edf3a51757db99aee38762c709146c320f62;p=openstack-build%2Fcinder-build.git Fix _migrate_up in test_migrations _migrate_up should always actually do a db upgrade whether or not it is being tested with data or not Change-Id: I28cbab36a5227903ff40a3243492b34d4b82a223 --- diff --git a/cinder/tests/test_migrations.py b/cinder/tests/test_migrations.py index 847eb4bf9..47b1050c5 100644 --- a/cinder/tests/test_migrations.py +++ b/cinder/tests/test_migrations.py @@ -353,13 +353,13 @@ class TestMigrations(test.TestCase): if prerun: data = prerun(engine) - migration_api.upgrade(engine, - TestMigrations.REPOSITORY, - version) - self.assertEqual( - version, - migration_api.db_version(engine, - TestMigrations.REPOSITORY)) + migration_api.upgrade(engine, + TestMigrations.REPOSITORY, + version) + self.assertEqual( + version, + migration_api.db_version(engine, + TestMigrations.REPOSITORY)) if with_data: check = getattr(self, "_check_%3.3d" % version, None)