Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
persistent
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
persistent
Commits
db732a81
Commit
db732a81
authored
Dec 14, 2012
by
Tres Seaver
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Aim for consistent repr of timestamp between C and Python impl.
parent
bbdaeeba
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
3 deletions
+2
-3
persistent/tests/test_timestamp.py
persistent/tests/test_timestamp.py
+1
-2
persistent/timestamp.py
persistent/timestamp.py
+1
-1
No files found.
persistent/tests/test_timestamp.py
View file @
db732a81
...
...
@@ -148,10 +148,9 @@ class pyTimeStampTests(unittest.TestCase):
def
test_repr
(
self
):
from
persistent.timestamp
import
_makeOctets
from
persistent._compat
import
_native
SERIAL
=
_makeOctets
(
'
\
x01
'
*
8
)
ts
=
self
.
_makeOne
(
SERIAL
)
self
.
assertEqual
(
repr
(
ts
),
_native
(
SERIAL
))
self
.
assertEqual
(
repr
(
ts
),
repr
(
SERIAL
))
class
TimeStampTests
(
pyTimeStampTests
):
...
...
persistent/timestamp.py
View file @
db732a81
...
...
@@ -90,7 +90,7 @@ class pyTimeStamp(object):
return
self
.
_raw
def
__repr__
(
self
):
return
_native
(
self
.
_raw
)
return
repr
(
self
.
_raw
)
def
year
(
self
):
return
self
.
_elements
[
0
]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment