Esempio n. 1
0
 def test_azimuth_northwest(self):
     result = azimuth(Point(100,100), Point(99, 101))
     expected_result = 315
     self.assertEqual(result, expected_result) 
Esempio n. 2
0
 def test_azimuth_west(self):
     result = azimuth(Point(0,0), Point(-10,0))
     expected_result = 270
     self.assertEqual(result, expected_result) 
 def test_azimuth_southwest(self):
     result = azimuth(Point(0, 0), Point(-1, -1))
     expected_result = 225
     self.assertEqual(expected_result, result)
 def test_azimuth_northeast(self):
     result = azimuth(Point(0, 0), Point(1, 1))
     expected_result = 45
     self.assertEqual(expected_result, result)
 def test_azimuth_south(self):
     result = azimuth(Point(0, 0), Point(0, -1))
     expected_result = 180
     self.assertEqual(expected_result, result)
 def test_azimuth_southeast(self):
     result = azimuth(Point(0, 0), Point(1, -1))
     expected_result = 135
     self.assertEqual(result, expected_result)
 def test_azimuth_north(self):
     result = azimuth(Point(0, 0), Point(0, 1))
     expected_result = 0
     self.assertEqual(result, expected_result)