Commit f8978f7e authored by Michal Čihař's avatar Michal Čihař

Silence Python 3 deprecation warnings

Signed-off-by: default avatarMichal Čihař <michal@cihar.com>
parent 553fb910
......@@ -22,6 +22,8 @@ from unittest import TestCase
from django.core.exceptions import ImproperlyConfigured
from six import assertRaisesRegex
from weblate.trans.util import load_class
......@@ -31,7 +33,7 @@ class LoadClassTest(TestCase):
self.assertEqual(cls, TestCase)
def test_invalid_name(self):
self.assertRaisesRegexp(
assertRaisesRegex(
ImproperlyConfigured,
'Error importing class unittest in TEST: .*"'
'(not enough|need more than)',
......@@ -39,7 +41,7 @@ class LoadClassTest(TestCase):
)
def test_invalid_module(self):
self.assertRaisesRegexp(
assertRaisesRegex(
ImproperlyConfigured,
'weblate.trans.tests.missing in TEST: "'
'No module named .*missing["\']',
......@@ -47,7 +49,7 @@ class LoadClassTest(TestCase):
)
def test_invalid_class(self):
self.assertRaisesRegexp(
assertRaisesRegex(
ImproperlyConfigured,
'"weblate.trans.tests.test_utils" does not define a "Foo" class',
load_class, 'weblate.trans.tests.test_utils.Foo', 'TEST'
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment