def test_simple_conversion(self): UT = '2000-01-01T12:00:00.00' self.assertAlmostEqual(utils.azel2pGBT(120, 88, UT) % 360, self.nieve_conversion(120, 88) % 360, 0) self.assertAlmostEqual(utils.azel2pGBT(15, 5, UT) % 360, self.nieve_conversion(15, 5) % 360, 0) self.assertAlmostEqual(utils.azel2pGBT(210, 30, UT) % 360, self.nieve_conversion(210, 30) % 360, 0)
def test_simple_conversion(self): UT = '2000-01-01T12:00:00.00' self.assertAlmostEqual( utils.azel2pGBT(120, 88, UT) % 360, self.nieve_conversion(120, 88) % 360, 0) self.assertAlmostEqual( utils.azel2pGBT(15, 5, UT) % 360, self.nieve_conversion(15, 5) % 360, 0) self.assertAlmostEqual( utils.azel2pGBT(210, 30, UT) % 360, self.nieve_conversion(210, 30) % 360, 0)
def test_known_cases(self): UT = '2000-01-01T12:00:00.00' self.assertAlmostEqual(utils.azel2pGBT(0, 60, UT) % 360, 180, 1) self.assertAlmostEqual(utils.azel2pGBT(90, 89.99, UT) % 360, 270, 1) self.assertAlmostEqual(utils.azel2pGBT(270, 89.99, UT) % 360, 90, 1)