MCPcopy Index your code
hub / github.com/python/cpython / test_normal

Method test_normal

Lib/test/datetimetester.py:200–206  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

198 self.assertRaises(NotImplementedError, ne.dst, dt)
199
200 def test_normal(self):
201 fo = FixedOffset(3, "Three")
202 self.assertIsInstance(fo, tzinfo)
203 for dt in datetime.now(), None:
204 self.assertEqual(fo.utcoffset(dt), timedelta(minutes=3))
205 self.assertEqual(fo.tzname(dt), "Three")
206 self.assertEqual(fo.dst(dt), timedelta(minutes=42))
207
208 def test_pickling_base(self):
209 # There's no point to pickling tzinfo objects on their own (they

Callers

nothing calls this directly

Calls 8

utcoffsetMethod · 0.95
tznameMethod · 0.95
dstMethod · 0.95
timedeltaClass · 0.90
FixedOffsetClass · 0.85
assertIsInstanceMethod · 0.80
nowMethod · 0.80
assertEqualMethod · 0.45

Tested by

no test coverage detected