summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_kqueue.py
diff options
context:
space:
mode:
authorEzio Melotti <ezio.melotti@gmail.com>2010-11-20 19:04:17 (GMT)
committerEzio Melotti <ezio.melotti@gmail.com>2010-11-20 19:04:17 (GMT)
commitb3aedd48621ed9d33b5f42f946b256bce4a50673 (patch)
tree2297c8ebce1b09621e1d98096c1603896d9a0f0c /Lib/test/test_kqueue.py
parentb8bc439b2093add9b313bcca2cc507a2d0e87764 (diff)
downloadcpython-b3aedd48621ed9d33b5f42f946b256bce4a50673.zip
cpython-b3aedd48621ed9d33b5f42f946b256bce4a50673.tar.gz
cpython-b3aedd48621ed9d33b5f42f946b256bce4a50673.tar.bz2
#9424: Replace deprecated assert* methods in the Python test suite.
Diffstat (limited to 'Lib/test/test_kqueue.py')
-rw-r--r--Lib/test/test_kqueue.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/Lib/test/test_kqueue.py b/Lib/test/test_kqueue.py
index 3d0428e..9cb0a85 100644
--- a/Lib/test/test_kqueue.py
+++ b/Lib/test/test_kqueue.py
@@ -91,7 +91,7 @@ class TestKQueue(unittest.TestCase):
try:
client.connect(('127.0.0.1', serverSocket.getsockname()[1]))
except socket.error as e:
- self.assertEquals(e.args[0], errno.EINPROGRESS)
+ self.assertEqual(e.args[0], errno.EINPROGRESS)
else:
#raise AssertionError("Connect should have raised EINPROGRESS")
pass # FreeBSD doesn't raise an exception here
@@ -125,7 +125,7 @@ class TestKQueue(unittest.TestCase):
events = kq.control(None, 4, 1)
events = [(e.ident, e.filter, e.flags) for e in events]
events.sort()
- self.assertEquals(events, [
+ self.assertEqual(events, [
(client.fileno(), select.KQ_FILTER_WRITE, flags),
(server.fileno(), select.KQ_FILTER_WRITE, flags)])
@@ -144,7 +144,7 @@ class TestKQueue(unittest.TestCase):
events = [(e.ident, e.filter, e.flags) for e in events]
events.sort()
- self.assertEquals(events, [
+ self.assertEqual(events, [
(client.fileno(), select.KQ_FILTER_WRITE, flags),
(client.fileno(), select.KQ_FILTER_READ, flags),
(server.fileno(), select.KQ_FILTER_WRITE, flags),
@@ -167,7 +167,7 @@ class TestKQueue(unittest.TestCase):
events = kq.control([], 4, 0.99)
events = [(e.ident, e.filter, e.flags) for e in events]
events.sort()
- self.assertEquals(events, [
+ self.assertEqual(events, [
(server.fileno(), select.KQ_FILTER_WRITE, flags)])
client.close()
@@ -184,7 +184,7 @@ class TestKQueue(unittest.TestCase):
r = kq.control([event1, event2], 1, 1)
self.assertTrue(r)
self.assertFalse(r[0].flags & select.KQ_EV_ERROR)
- self.assertEquals(b.recv(r[0].data), b'foo')
+ self.assertEqual(b.recv(r[0].data), b'foo')
a.close()
b.close()