summaryrefslogtreecommitdiffstats
path: root/Lib/test
diff options
context:
space:
mode:
authorIvan Levkivskyi <levkivskyi@gmail.com>2017-09-13 23:25:15 (GMT)
committerƁukasz Langa <lukasz@langa.pl>2017-09-13 23:25:15 (GMT)
commit65bc62052fe5d550cb14c0033e8a2550618fb7b9 (patch)
tree6980d9a0af62cb7793b5da83fb33511ae31514c9 /Lib/test
parentf6e61df01536493f1280cd07639c7ff9bffb2cdc (diff)
downloadcpython-65bc62052fe5d550cb14c0033e8a2550618fb7b9.zip
cpython-65bc62052fe5d550cb14c0033e8a2550618fb7b9.tar.gz
cpython-65bc62052fe5d550cb14c0033e8a2550618fb7b9.tar.bz2
bpo-28556: Minor updates to typing module (#3550)
* Copy changes to typing from upstream repo * Add NEWS entry
Diffstat (limited to 'Lib/test')
-rw-r--r--Lib/test/test_typing.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/Lib/test/test_typing.py b/Lib/test/test_typing.py
index fd2d93c..a351be1 100644
--- a/Lib/test/test_typing.py
+++ b/Lib/test/test_typing.py
@@ -1069,6 +1069,13 @@ class GenericTests(BaseTestCase):
for t in things + [Any]:
self.assertEqual(t, copy(t))
self.assertEqual(t, deepcopy(t))
+ if sys.version_info >= (3, 3):
+ # From copy module documentation:
+ # It does "copy" functions and classes (shallow and deeply), by returning
+ # the original object unchanged; this is compatible with the way these
+ # are treated by the pickle module.
+ self.assertTrue(t is copy(t))
+ self.assertTrue(t is deepcopy(t))
def test_weakref_all(self):
T = TypeVar('T')