(self)
| 5002 | self.assertEqual(derived.tzname(), 'cookie') |
| 5003 | |
| 5004 | def test_extreme_hashes(self): |
| 5005 | # If an attempt is made to hash these via subtracting the offset |
| 5006 | # then hashing a datetime object, OverflowError results. The |
| 5007 | # Python implementation used to blow up here. |
| 5008 | t = self.theclass(1, 1, 1, tzinfo=FixedOffset(1439, "")) |
| 5009 | hash(t) |
| 5010 | t = self.theclass(MAXYEAR, 12, 31, 23, 59, 59, 999999, |
| 5011 | tzinfo=FixedOffset(-1439, "")) |
| 5012 | hash(t) |
| 5013 | |
| 5014 | # OTOH, an OOB offset should blow up. |
| 5015 | t = self.theclass(5, 5, 5, tzinfo=FixedOffset(-1440, "")) |
| 5016 | self.assertRaises(ValueError, hash, t) |
| 5017 | |
| 5018 | def test_zones(self): |
| 5019 | est = FixedOffset(-300, "EST") |
nothing calls this directly
no test coverage detected