summaryrefslogtreecommitdiff
path: root/tests/test_popen_spawn.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_popen_spawn.py')
-rw-r--r--tests/test_popen_spawn.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/test_popen_spawn.py b/tests/test_popen_spawn.py
index fca7493..6168148 100644
--- a/tests/test_popen_spawn.py
+++ b/tests/test_popen_spawn.py
@@ -110,13 +110,13 @@ class ExpectTestCase (PexpectTestCase.PexpectTestCase):
def test_bad_arg(self):
p = PopenSpawn('cat')
- with self.assertRaisesRegexp(TypeError, '.*must be one of'):
+ with self.assertRaisesRegex(TypeError, '.*must be one of'):
p.expect(1)
- with self.assertRaisesRegexp(TypeError, '.*must be one of'):
+ with self.assertRaisesRegex(TypeError, '.*must be one of'):
p.expect([1, b'2'])
- with self.assertRaisesRegexp(TypeError, '.*must be one of'):
+ with self.assertRaisesRegex(TypeError, '.*must be one of'):
p.expect_exact(1)
- with self.assertRaisesRegexp(TypeError, '.*must be one of'):
+ with self.assertRaisesRegex(TypeError, '.*must be one of'):
p.expect_exact([1, b'2'])
def test_timeout_none(self):
@@ -136,4 +136,4 @@ class ExpectTestCase (PexpectTestCase.PexpectTestCase):
if __name__ == '__main__':
unittest.main()
-suite = unittest.makeSuite(ExpectTestCase, 'test')
+suite = unittest.TestLoader().loadTestsFromTestCase(ExpectTestCase)