kopia lustrzana https://github.com/micropython/micropython-lib
quopri: test_quopri.py: Patch for MicroPython compatibility.
rodzic
190ac118f8
commit
7f97a5c581
|
@ -59,7 +59,7 @@ def withpythonimplementation(testfunc):
|
|||
finally:
|
||||
quopri.b2a_qp = oldencode
|
||||
quopri.a2b_qp = olddecode
|
||||
newtest.__name__ = testfunc.__name__
|
||||
# newtest.__name__ = testfunc.__name__
|
||||
return newtest
|
||||
|
||||
class QuopriTestCase(unittest.TestCase):
|
||||
|
@ -174,7 +174,7 @@ zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz''')
|
|||
for p, e in self.HSTRINGS:
|
||||
self.assertEqual(quopri.decodestring(e, header=True), p)
|
||||
|
||||
def test_scriptencode(self):
|
||||
def _test_scriptencode(self):
|
||||
(p, e) = self.STRINGS[-1]
|
||||
process = subprocess.Popen([sys.executable, "-mquopri"],
|
||||
stdin=subprocess.PIPE, stdout=subprocess.PIPE)
|
||||
|
@ -190,7 +190,7 @@ zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz''')
|
|||
self.assertEqual(cout[i], e[i])
|
||||
self.assertEqual(cout, e)
|
||||
|
||||
def test_scriptdecode(self):
|
||||
def _test_scriptdecode(self):
|
||||
(p, e) = self.STRINGS[-1]
|
||||
process = subprocess.Popen([sys.executable, "-mquopri", "-d"],
|
||||
stdin=subprocess.PIPE, stdout=subprocess.PIPE)
|
||||
|
|
Ładowanie…
Reference in New Issue