Skip to content

test_parse_date #218

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
yarikoptic opened this issue Dec 18, 2014 · 0 comments
Closed

test_parse_date #218

yarikoptic opened this issue Dec 18, 2014 · 0 comments
Milestone

Comments

@yarikoptic
Copy link
Contributor

as originally discussed in #216 and now moved outside

I am a bit uncertain if the test rests on correct assumptions:

 99             rfc = ("Thu, 07 Apr 2005 22:13:11 +0000", 0)
100             iso = ("2005-04-07T22:13:11 -0200", 7200)
101             iso2 = ("2005-04-07 22:13:11 +0400", -14400)
102             iso3 = ("2005.04.07 22:13:11 -0000", 0)
103             alt = ("04/07/2005 22:13:11", 0)
104             alt2 = ("07.04.2005 22:13:11", 0)
105             veri_time = 1112904791      # the time this represents
(Pdb) 
106             for date, offset in (rfc, iso, iso2, iso3, alt, alt2):
107  ->             assert_rval(parse_date(date), veri_time, offset)

while date says it was 20 not 22 hours at UTC

$> date -u --date='@1112904791' 
Thu Apr  7 20:13:11 UTC 2005

changing to 1112911991 (prev + 2 hours) doesn't resolve the problem though

@Byron Byron added this to the v0.3.3 milestone Dec 19, 2014
@Byron Byron closed this as completed in 4a47a9c Dec 19, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants