summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2013-10-19 18:14:57 (GMT)
committerSerhiy Storchaka <storchaka@gmail.com>2013-10-19 18:14:57 (GMT)
commit0e071c967cfdc32c1c4c9a8ab6d6f4777dba267e (patch)
tree55f51950321e4d080c4b6cc796c7b0c6fbadf184
parentb649ed746ebad735a9f340b720eed674dd1885e6 (diff)
downloadcpython-0e071c967cfdc32c1c4c9a8ab6d6f4777dba267e.zip
cpython-0e071c967cfdc32c1c4c9a8ab6d6f4777dba267e.tar.gz
cpython-0e071c967cfdc32c1c4c9a8ab6d6f4777dba267e.tar.bz2
Fixed tests for issue #19279.
-rw-r--r--Lib/test/test_codecs.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/Lib/test/test_codecs.py b/Lib/test/test_codecs.py
index 80ec541..3517057 100644
--- a/Lib/test/test_codecs.py
+++ b/Lib/test/test_codecs.py
@@ -840,10 +840,9 @@ class UTF7Test(ReadTest, unittest.TestCase):
(b'a+////,+IKw-b', 'a\uffff\ufffd\u20acb'),
]
for raw, expected in tests:
- with self.subTest(raw=raw):
- self.assertRaises(UnicodeDecodeError, codecs.utf_7_decode,
- raw, 'strict', True)
- self.assertEqual(raw.decode('utf-7', 'replace'), expected)
+ self.assertRaises(UnicodeDecodeError, codecs.utf_7_decode,
+ raw, 'strict', True)
+ self.assertEqual(raw.decode('utf-7', 'replace'), expected)
def test_nonbmp(self):
self.assertEqual('\U000104A0'.encode(self.encoding), b'+2AHcoA-')