mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
Use sequence repetition instead of bytes constructor with integer argument.
This commit is contained in:
parent
ab8740058a
commit
5f1a5187f7
12 changed files with 20 additions and 20 deletions
|
@ -1812,7 +1812,7 @@ class BufferedRWPairTest(unittest.TestCase):
|
|||
with self.subTest(method):
|
||||
pair = self.tp(self.BytesIO(b"abcdef"), self.MockRawIO())
|
||||
|
||||
data = byteslike(5)
|
||||
data = byteslike(b'\0' * 5)
|
||||
self.assertEqual(getattr(pair, method)(data), 5)
|
||||
self.assertEqual(bytes(data), b"abcde")
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue