Example #1
0
    def test_get_azimuth_elev_deg(self):
        date = datetime.datetime.strptime("2014-10-21 22:47:29.147740",
                                          '%Y-%m-%d %H:%M:%S.%f')
        azimuth, elevation = ARG.get_azimuth_elev_deg(
            self.predictor.get_position(date))

        self.assertAlmostEqual(azimuth, 249.7, delta=0.1)
        self.assertAlmostEqual(elevation, -52.1, delta=0.1)
 def test_predicted_passes_whit_aos(self):
     end = self.start + timedelta(days=60)
     for pass_ in self.predictor.passes_over(ARG,
                                             self.start,
                                             end,
                                             aos_at_dg=5):
         self.assertGreater(pass_.max_elevation_deg, 5)
         position = self.predictor.get_position(pass_.aos)
         _, elev = ARG.get_azimuth_elev_deg(position)
         self.assertAlmostEqual(elev, 5, delta=0.1)