Skip to content

Commit 1bc5068

Browse files
committed
[FT] Clear the idl lock in TestMaintenance tests
One or the other test in TestMaintenance fails randomly with missing idl lock. DBInconsistenciesPeriodics set's the idl lock but in TestMaintenance we don't run it as a seperate maintenance worker and instead call check_for_inconsistencies when needed so not a requirement to have a dedicated lock. This patch clears the lock for these tests to avoid such random issues. Closes-Bug: #2039417 Change-Id: I931997fe010295120f2400b1ec310dff82497ab6 (cherry picked from commit 39a1f1e)
1 parent 60b4c47 commit 1bc5068

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

neutron/tests/functional/plugins/ml2/drivers/ovn/mech_driver/ovsdb/test_maintenance.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,8 @@ def setUp(self):
5050
ext_mgr = test_extraroute.ExtraRouteTestExtensionManager()
5151
self.ext_api = test_extensions.setup_extensions_middleware(ext_mgr)
5252
self.maint = maintenance.DBInconsistenciesPeriodics(self._ovn_client)
53+
# Release the unneeded lock
54+
self.maint._idl.set_lock(None)
5355
self.context = n_context.get_admin_context()
5456
# Always verify inconsistencies for all objects.
5557
db_rev.INCONSISTENCIES_OLDER_THAN = -1

0 commit comments

Comments
 (0)