summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author张酉夫 <zhangyoufu@gmail.com>2019-12-19 11:59:12 +0800
committerMarcel Hellkamp <marc@gsites.de>2019-12-19 13:22:28 +0100
commit71fc15feb22f8afd3ccf5df461917fd94d4b3c2d (patch)
treeaf7e29ecee91872b99b173eb46130cdbdf074e8b
parent73ffccef399d3b1b1bb26509f17eed25273a4679 (diff)
downloadbottle-71fc15feb22f8afd3ccf5df461917fd94d4b3c2d.tar.gz
fix test case
setting expires with naive datetime is treated as UTC time
-rwxr-xr-xtest/test_environ.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/test_environ.py b/test/test_environ.py
index 4b736af..908b9d8 100755
--- a/test/test_environ.py
+++ b/test/test_environ.py
@@ -760,7 +760,7 @@ class TestResponse(unittest.TestCase):
def test_expires_header(self):
import datetime
response = BaseResponse()
- now = datetime.datetime.now()
+ now = datetime.datetime.utcnow()
response.expires = now
def seconds(a, b):