summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_telnetlib.py
diff options
context:
space:
mode:
authorZachary Ware <zachary.ware@gmail.com>2015-12-05 05:32:23 (GMT)
committerZachary Ware <zachary.ware@gmail.com>2015-12-05 05:32:23 (GMT)
commitac28b796d80f869f39662491446145106960a886 (patch)
tree1877f8c5cd3a304a1890e81034555987fd9afbc1 /Lib/test/test_telnetlib.py
parent939614c48c3b0b5adeb408294a032118411ab987 (diff)
downloadcpython-ac28b796d80f869f39662491446145106960a886.zip
cpython-ac28b796d80f869f39662491446145106960a886.tar.gz
cpython-ac28b796d80f869f39662491446145106960a886.tar.bz2
Issue #25795: Fix several tests to run independently.
These were broken in 3aec776fc796 when they were converted away from using support.run_unittest(). Oops :) Initial patch by Felippe da Motta Raposo.
Diffstat (limited to 'Lib/test/test_telnetlib.py')
-rw-r--r--Lib/test/test_telnetlib.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/Lib/test/test_telnetlib.py b/Lib/test/test_telnetlib.py
index 524bba3..6c27c16 100644
--- a/Lib/test/test_telnetlib.py
+++ b/Lib/test/test_telnetlib.py
@@ -4,8 +4,8 @@ import telnetlib
import time
import contextlib
-from unittest import TestCase
from test import support
+import unittest
threading = support.import_module('threading')
HOST = support.HOST
@@ -21,7 +21,7 @@ def server(evt, serv):
finally:
serv.close()
-class GeneralTests(TestCase):
+class GeneralTests(unittest.TestCase):
def setUp(self):
self.evt = threading.Event()
@@ -165,7 +165,7 @@ def test_telnet(reads=(), cls=TelnetAlike):
telnet._messages = '' # debuglevel output
return telnet
-class ExpectAndReadTestCase(TestCase):
+class ExpectAndReadTestCase(unittest.TestCase):
def setUp(self):
self.old_selector = telnetlib._TelnetSelector
telnetlib._TelnetSelector = MockSelector
@@ -284,7 +284,7 @@ class nego_collector(object):
tl = telnetlib
-class WriteTests(TestCase):
+class WriteTests(unittest.TestCase):
'''The only thing that write does is replace each tl.IAC for
tl.IAC+tl.IAC'''
@@ -300,7 +300,7 @@ class WriteTests(TestCase):
written = b''.join(telnet.sock.writes)
self.assertEqual(data.replace(tl.IAC,tl.IAC+tl.IAC), written)
-class OptionTests(TestCase):
+class OptionTests(unittest.TestCase):
# RFC 854 commands
cmds = [tl.AO, tl.AYT, tl.BRK, tl.EC, tl.EL, tl.GA, tl.IP, tl.NOP]