From 56da348b4933de441986a353e1782cf498211344 Mon Sep 17 00:00:00 2001 From: Vishakha Agarwal Date: Wed, 5 Aug 2020 21:36:26 +0530 Subject: [PATCH] Skip tests to update u-c for PyMySql to 0.10.0 In the new version of PyMySql the error > 1000, will be operational error [1], which is failing keystone migration test cases [2] for backend mysql because we raise dberror [3] which does not handle operational error. PyMySQL hasn't been raised to 0.10.0 in the upper-constraints yet, so this patch isn't going to be able to install it. We can't raise the u-c since the current keystone jobs are failing with it. This patch overrides the test cases for backend SQL and skips the same. This is so to make sure that failed test cases are skipped because Once the upper-constraints are updated to 0.10.0 for PyMySql and merged, will revert the skip and handle for 0.10.0. [1]https://github.com/PyMySQL/PyMySQL/commit/c3e5a63514c57d1f4c9d5e7bf4b7e10b0608b0e1 [2]https://da7bb9864083b9045f13-6176f3344d2541229da3be8329641f28.ssl.cf5.rackcdn.com/741837/2/check/cross-keystone-py36/d1a2e73/testr_results.html [3]https://github.com/openstack/keystone/blob/033e7aff870f2ccd4dec607e9c47efff630ece29/keystone/tests/unit/test_sql_upgrade.py#L1867 Related-Bug: #1890325 Change-Id: I207bb816affcb3e2725321de9a90a40c027a9f87 --- keystone/tests/unit/test_sql_upgrade.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/keystone/tests/unit/test_sql_upgrade.py b/keystone/tests/unit/test_sql_upgrade.py index 22cb442600..79bd8f409f 100644 --- a/keystone/tests/unit/test_sql_upgrade.py +++ b/keystone/tests/unit/test_sql_upgrade.py @@ -3503,6 +3503,14 @@ class FullMigration(SqlMigrateBase, unit.TestCase): class MySQLOpportunisticFullMigration(FullMigration): FIXTURE = db_fixtures.MySQLOpportunisticFixture + def test_migration_003_migrate_unencrypted_credentials(self): + self.skip_test_overrides('skipped to update u-c for PyMySql version' + 'to 0.10.0') + + def test_migration_012_add_domain_id_to_idp(self): + self.skip_test_overrides('skipped to update u-c for PyMySql version' + 'to 0.10.0') + class PostgreSQLOpportunisticFullMigration(FullMigration): FIXTURE = db_fixtures.PostgresqlOpportunisticFixture