From 21b365b140dd87e9986f310802dbb26f8695740e Mon Sep 17 00:00:00 2001 From: Thomas Goirand Date: Mon, 29 Dec 2025 11:31:43 +0100 Subject: [PATCH] Python 3.14: fix assertRaises Python 3.14 tightened call semantics, and testtools 2.8.2 no longer tolerates unittest-style kwargs, when Nova tests were mixing testtools.TestCase with unittest. This patch fixes this by using positional arguments for assertRaises. Signed-off-by: Thomas Goirand Change-Id: Ic589880d4759336ab6ceec5057eafe223f692caa --- nova/tests/unit/virt/libvirt/volume/test_quobyte.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/nova/tests/unit/virt/libvirt/volume/test_quobyte.py b/nova/tests/unit/virt/libvirt/volume/test_quobyte.py index bb3c86083c..b49126f721 100644 --- a/nova/tests/unit/virt/libvirt/volume/test_quobyte.py +++ b/nova/tests/unit/virt/libvirt/volume/test_quobyte.py @@ -264,9 +264,9 @@ class QuobyteTestCase(test.NoDBTestCase): stat_mock.side_effect = [os.stat, statMockCall] self.assertRaises( - excClass=nova_exception.InvalidVolume, - callableObj=drv.validate_volume, - mount_path=self.TEST_MNT_POINT) + nova_exception.InvalidVolume, + drv.validate_volume, + self.TEST_MNT_POINT) stat_mock.assert_called_with(self.TEST_MNT_POINT) part_mock.assert_called_once_with(all=True)