diff options
author | Jenkins <jenkins@review.openstack.org> | 2017-06-07 22:03:01 +0000 |
---|---|---|
committer | Gerrit Code Review <review@openstack.org> | 2017-06-07 22:03:01 +0000 |
commit | bef4bfbc7c6e860bd599928421447153f0136efe (patch) | |
tree | 0ad8863e87c6468896fcd99842b1307fe001fa4a /nova/tests | |
parent | f7f246389566e4f293c63c369d7633ab88196d94 (diff) | |
parent | f89909658a8e0087864f4486f4a1b40edf42d6cd (diff) | |
download | nova-bef4bfbc7c6e860bd599928421447153f0136efe.tar.gz |
Merge "placement: use separate tables for projects/users"
Diffstat (limited to 'nova/tests')
-rw-r--r-- | nova/tests/functional/db/api/test_migrations.py | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/nova/tests/functional/db/api/test_migrations.py b/nova/tests/functional/db/api/test_migrations.py index fc6ffd5c61..82309c6b02 100644 --- a/nova/tests/functional/db/api/test_migrations.py +++ b/nova/tests/functional/db/api/test_migrations.py @@ -620,6 +620,27 @@ class NovaAPIMigrationsWalk(test_migrations.WalkVersionsMixin): 'consumers_project_id_user_id_uuid_idx') self.assertUniqueConstraintExists(engine, 'consumers', ['uuid']) + def _check_044(self, engine, data): + for column in ['created_at', 'updated_at', 'id', 'external_id']: + self.assertColumnExists(engine, 'projects', column) + self.assertColumnExists(engine, 'users', column) + + self.assertUniqueConstraintExists(engine, 'projects', ['external_id']) + self.assertUniqueConstraintExists(engine, 'users', ['external_id']) + + # We needed to drop and recreate columns and indexes on consumers, so + # check that worked out properly + self.assertColumnExists(engine, 'consumers', 'project_id') + self.assertColumnExists(engine, 'consumers', 'user_id') + self.assertIndexExists( + engine, 'consumers', + 'consumers_project_id_uuid_idx', + ) + self.assertIndexExists( + engine, 'consumers', + 'consumers_project_id_user_id_uuid_idx', + ) + class TestNovaAPIMigrationsWalkSQLite(NovaAPIMigrationsWalk, test_base.DbTestCase, |