summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_typing.py
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2017-09-14 00:10:53 (GMT)
committerƁukasz Langa <lukasz@langa.pl>2017-09-14 00:10:53 (GMT)
commit9e3cd78ec18b2d2078d30b04307916acd68be37a (patch)
treeb74ebe9e3bbb2f30be2b7efb26c2e63484c5f670 /Lib/test/test_typing.py
parentef323e8d82b07d4e7e4303c360dc32d3de0b3147 (diff)
downloadcpython-9e3cd78ec18b2d2078d30b04307916acd68be37a.zip
cpython-9e3cd78ec18b2d2078d30b04307916acd68be37a.tar.gz
cpython-9e3cd78ec18b2d2078d30b04307916acd68be37a.tar.bz2
[3.6] bpo-28556: Minor updates to typing module (GH-3550) (#3558)
* Copy changes to typing from upstream repo * Add NEWS entry (cherry picked from commit 65bc62052fe5d550cb14c0033e8a2550618fb7b9)
Diffstat (limited to 'Lib/test/test_typing.py')
-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 6d0b265..ff634e8 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')