From b1bcd6b2f8abc999256a9b887793b37a16604509 Mon Sep 17 00:00:00 2001 From: Rick Harris Date: Wed, 27 Feb 2013 23:04:40 +0000 Subject: [PATCH] BM Migration 004: Actually drop column SQLAlchemy-migrate appears to support passing in a Column or a column-name string into `drop_column`. In practice though, only the column-name form actually works. Change-Id: I1bcc28511d652df44f7168fb84c8be7dacd60cfd --- nova/tests/test_migrations.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/nova/tests/test_migrations.py b/nova/tests/test_migrations.py index e090044c..05412863 100644 --- a/nova/tests/test_migrations.py +++ b/nova/tests/test_migrations.py @@ -971,3 +971,7 @@ class TestBaremetalMigrations(BaseMigrationTestCase, CommonTestsMixIn): def _check_002(self, engine, data): self.assertRaises(sqlalchemy.exc.NoSuchTableError, get_table, engine, 'bm_deployments') + + def _post_downgrade_004(self, engine): + bm_nodes = get_table(engine, 'bm_nodes') + self.assertNotIn(u'instance_name', [c.name for c in bm_nodes.columns])