Got rid of the timetz type entirely. This was a bit trickier than I

hoped it would be, but not too bad.  A test had to change:
time.__setstate__() can no longer add a non-None tzinfo member to a time
object that didn't already have one, since storage for a tzinfo member
doesn't exist in that case.
This commit is contained in:
Tim Peters 2003-01-10 03:49:02 +00:00
parent a5e8bb94e5
commit 37f398282b
3 changed files with 369 additions and 504 deletions

View file

@ -1857,7 +1857,7 @@ class TestTimeTZ(TestTime, TZInfoBase):
tinfo = PicklableFixedOffset(-300, 'cookie')
orig = self.theclass(5, 6, 7, tzinfo=tinfo)
state = orig.__getstate__()
derived = self.theclass()
derived = self.theclass(tzinfo=FixedOffset(0, "UTC", 0))
derived.__setstate__(state)
self.assertEqual(orig, derived)
self.failUnless(isinstance(derived.tzinfo, PicklableFixedOffset))