MCPcopy
hub / github.com/django/django / test_parsing_rfc1123

Method test_parsing_rfc1123

tests/utils_tests/test_http.py:346–351  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

344 self.assertEqual(http_date(t), "Mon, 01 Jan 2007 01:54:21 GMT")
345
346 def test_parsing_rfc1123(self):
347 parsed = parse_http_date("Sun, 06 Nov 1994 08:49:37 GMT")
348 self.assertEqual(
349 datetime.fromtimestamp(parsed, UTC),
350 datetime(1994, 11, 6, 8, 49, 37, tzinfo=UTC),
351 )
352
353 @unittest.skipIf(platform.architecture()[0] == "32bit", "The Year 2038 problem.")
354 @mock.patch("django.utils.http.datetime")

Callers

nothing calls this directly

Calls 1

parse_http_dateFunction · 0.90

Tested by

no test coverage detected