Replace assertRaisesRegexp with assertRaisesRegex
This replaces the deprecated (in python 3.2) unittest.TestCase method assertRaisesRegexp() with assertRaisesRegex(). Change-Id: I5a2c42765ee0ce660c40ac43a078943125746c71 Signed-off-by: Chuck Short <chucks@redhat.com>
This commit is contained in:
parent
d42343deea
commit
c8235723f9
|
@ -1629,7 +1629,7 @@ class PXERamdiskDeployTestCase(db_base.DbTestCase):
|
|||
self.config(enabled_boot_interfaces=['fake'],
|
||||
default_boot_interface='fake')
|
||||
with task_manager.acquire(self.context, node.uuid) as task:
|
||||
self.assertRaisesRegexp(exception.InvalidParameterValue,
|
||||
self.assertRaisesRegex(exception.InvalidParameterValue,
|
||||
'must have the `ramdisk_boot` capability',
|
||||
task.driver.deploy.validate, task)
|
||||
self.assertFalse(mock_validate_image.called)
|
||||
|
|
Loading…
Reference in New Issue