def test_datetime2Juldate(self): jd = date2juldate(datetime(2013, 3, 8, 11, 20, 45)) self.assertAlmostEqual(jd, 41341.47274305556)
def testdate2JulDate(self): for d, jd, y, ts in self.dates: self.assertEqual(jd, date2juldate(d))
def test_datetime2Juldate(): jd = date2juldate(datetime(2013, 3, 8, 11, 20, 45)) assert jd == 41341.47274305556
def test_date2JulDate(dates): for d, jd, y, ts in dates: assert jd == date2juldate(d)