[py-svn] r32179 - in py/dist/py/path/svn: . testing
briandorsey at codespeak.net
briandorsey at codespeak.net
Mon Sep 11 18:51:11 CEST 2006
Author: briandorsey
Date: Mon Sep 11 18:51:11 2006
New Revision: 32179
Modified:
py/dist/py/path/svn/testing/test_urlcommand.py
py/dist/py/path/svn/urlcommand.py
Log:
Made the time.mktime() --> calendar.timegm() fix to urlcommand.py.
Modified: py/dist/py/path/svn/testing/test_urlcommand.py
==============================================================================
--- py/dist/py/path/svn/testing/test_urlcommand.py (original)
+++ py/dist/py/path/svn/testing/test_urlcommand.py Mon Sep 11 18:51:11 2006
@@ -35,9 +35,9 @@
assert info.last_author == 'hpk'
assert info.created_rev == 2256
assert info.kind == 'file'
- assert info.mtime == 1132851300.0
+ assert info.mtime == 1132854900.0
assert info.size == 165
- assert info.time == 1132851300000000.0
+ assert info.time == 1132854900000000.0
def test_svn_1_3(self):
line =" 4784 hpk 2 Jun 01 2004 __init__.py"
Modified: py/dist/py/path/svn/urlcommand.py
==============================================================================
--- py/dist/py/path/svn/urlcommand.py (original)
+++ py/dist/py/path/svn/urlcommand.py Mon Sep 11 18:51:11 2006
@@ -5,7 +5,7 @@
"""
-import os, sys, time, re
+import os, sys, time, re, calendar
import py
from py import path, process
from py.__.path import common
@@ -275,7 +275,7 @@
if t_result > t_now:
year -= 1
t_result = (year, month, day, hour, minute, 0,0,0,0)
- return time.mktime(t_result)
+ return calendar.timegm(t_result)
class PathEntry:
def __init__(self, ppart):
More information about the pytest-commit
mailing list