summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChuck Short <chucks@redhat.com>2018-08-27 09:47:55 -0400
committerChuck Short <chucks@redhat.com>2018-08-27 09:48:29 -0400
commit7072a7552dcb58a60d08c73c1d002fdf1c5a6202 (patch)
tree92f0c1d40fdfc312563caee679d2588c41c5f5dd
parent6d0aa062184b18536f235ae91422ae1a4fda8cca (diff)
downloadoslo-config-6.5.1.tar.gz
Replace assertRaisesRegexp with assertRaisesRegex6.5.16.5.0
This replaces the deprecated (in python 3.2) unittest.TestCase method assertRaisesRegexp() with assertRaisesRegex(). Change-Id: Iba92ef7a76d9392750a95e3bd603f364de4ec890 Signed-off-by: Chuck Short <chucks@redhat.com>
-rw-r--r--oslo_config/tests/test_cfg.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/oslo_config/tests/test_cfg.py b/oslo_config/tests/test_cfg.py
index ce347d0..4f7549e 100644
--- a/oslo_config/tests/test_cfg.py
+++ b/oslo_config/tests/test_cfg.py
@@ -4540,8 +4540,8 @@ class PortChoicesTestCase(BaseTestCase):
self.assertRaises(SystemExit, self.conf, ['--port', '8181'])
def test_choice_out_range(self):
- self.assertRaisesRegexp(ValueError, 'out of bounds',
- cfg.PortOpt, 'port', choices=[80, 65537, 0])
+ self.assertRaisesRegex(ValueError, 'out of bounds',
+ cfg.PortOpt, 'port', choices=[80, 65537, 0])
def test_conf_file_choice_value(self):
self.conf.register_opt(cfg.PortOpt('port',