summaryrefslogtreecommitdiffstats
path: root/tests/_sql_livetest.py
diff options
context:
space:
mode:
authorAdam Young <ayoung@redhat.com>2013-05-24 16:45:39 -0400
committerAdam Young <ayoung@redhat.com>2013-05-31 13:58:42 -0400
commit62abd5d85384416dc05aa0a449dab1694caec3e8 (patch)
tree635f77877d47d676c7008f6d6430adcf7e3bdd1a /tests/_sql_livetest.py
parentd67e31b70ca648c8ca0a3cb76f421b3be257d4c5 (diff)
downloadkeystone-62abd5d85384416dc05aa0a449dab1694caec3e8.tar.gz
keystone-62abd5d85384416dc05aa0a449dab1694caec3e8.tar.xz
keystone-62abd5d85384416dc05aa0a449dab1694caec3e8.zip
Live SQL migration tests
Make it possible to run the migration tests for the supported databases without editing the config files. Blueprint live-sql-gate Change-Id: Iaf14ad42333b0a0cd1f7d0fb37f135a8bf7af14a
Diffstat (limited to 'tests/_sql_livetest.py')
-rw-r--r--tests/_sql_livetest.py37
1 files changed, 37 insertions, 0 deletions
diff --git a/tests/_sql_livetest.py b/tests/_sql_livetest.py
new file mode 100644
index 00000000..d9890979
--- /dev/null
+++ b/tests/_sql_livetest.py
@@ -0,0 +1,37 @@
+# vim: tabstop=4 shiftwidth=4 softtabstop=4
+
+# Copyright 2013 Red Hat, Inc
+#
+# Licensed under the Apache License, Version 2.0 (the "License"); you may
+# not use this file except in compliance with the License. You may obtain
+# a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
+# License for the specific language governing permissions and limitations
+# under the License.
+
+import test_sql_upgrade
+
+from keystone import config
+
+CONF = config.CONF
+
+
+class PostgresqlMigrateTests(test_sql_upgrade.SqlUpgradeTests):
+ def config_files(self):
+ files = (test_sql_upgrade.SqlUpgradeTests.
+ _config_file_list[:])
+ files.append("backend_postgresql.conf")
+ return files
+
+
+class MysqlMigrateTests(test_sql_upgrade.SqlUpgradeTests):
+ def config_files(self):
+ files = (test_sql_upgrade.SqlUpgradeTests.
+ _config_file_list[:])
+ files.append("backend_mysql.conf")
+ return files