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

Method test_date

Lib/test/test_mailbox.py:1681–1686  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1679 self._check_sample(msg)
1680
1681 def test_date(self):
1682 # Use get_date() and set_date()
1683 msg = mailbox.MaildirMessage(_sample_message)
1684 self.assertLess(abs(msg.get_date() - time.time()), 60)
1685 msg.set_date(0.0)
1686 self.assertEqual(msg.get_date(), 0.0)
1687
1688 def test_info(self):
1689 # Use get_info() and set_info()

Callers

nothing calls this directly

Calls 6

get_dateMethod · 0.95
set_dateMethod · 0.95
absFunction · 0.85
assertLessMethod · 0.45
timeMethod · 0.45
assertEqualMethod · 0.45

Tested by

no test coverage detected