summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorAlexander Belopolsky <alexander.belopolsky@gmail.com>2016-03-25 19:46:55 (GMT)
committerAlexander Belopolsky <alexander.belopolsky@gmail.com>2016-03-25 19:46:55 (GMT)
commit16b698b095bfc6cd37b66a58536fb11a6884b557 (patch)
treeb2eecef447ab5e11e5be1678e9f8b504c2e1c99d /Lib
parentd7ac00e6209ae29fbd4c9dd71885c32ad4c7340e (diff)
parent1dcf4f9ee5b60f23291a377353b3dceca7cc9dc9 (diff)
downloadcpython-16b698b095bfc6cd37b66a58536fb11a6884b557.zip
cpython-16b698b095bfc6cd37b66a58536fb11a6884b557.tar.gz
cpython-16b698b095bfc6cd37b66a58536fb11a6884b557.tar.bz2
merge
Diffstat (limited to 'Lib')
-rw-r--r--Lib/test/datetimetester.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/Lib/test/datetimetester.py b/Lib/test/datetimetester.py
index 4f20ffd..1f992f9 100644
--- a/Lib/test/datetimetester.py
+++ b/Lib/test/datetimetester.py
@@ -3463,6 +3463,14 @@ class TestDateTimeTZ(TestDateTime, TZInfoBase, unittest.TestCase):
self.assertEqual(dt, local)
self.assertEqual(local.strftime("%z %Z"), "-0400 EDT")
+ @support.run_with_tz('EST+05EDT,M3.2.0,M11.1.0')
+ def test_astimezone_default_near_fold(self):
+ # Issue #26616.
+ u = datetime(2015, 11, 1, 5, tzinfo=timezone.utc)
+ t = u.astimezone()
+ s = t.astimezone()
+ self.assertEqual(t.tzinfo, s.tzinfo)
+
def test_aware_subtract(self):
cls = self.theclass