mirror of
https://github.com/python/cpython.git
synced 2025-08-24 18:55:00 +00:00
Issue #20791: copy.copy() now doesn't make a copy when the input is a bytes object. Initial patch by Peter Otten.
This commit is contained in:
parent
85736a7d2c
commit
dc9215f882
3 changed files with 5 additions and 1 deletions
|
@ -98,6 +98,7 @@ class TestCopy(unittest.TestCase):
|
|||
pass
|
||||
tests = [None, 42, 2**100, 3.14, True, False, 1j,
|
||||
"hello", "hello\u1234", f.__code__,
|
||||
b"world", bytes(range(256)),
|
||||
NewStyle, range(10), Classic, max, WithMetaclass]
|
||||
for x in tests:
|
||||
self.assertIs(copy.copy(x), x)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue