Exemple #1
0
 def test_parse_planetary_routes(self):
     api_result, _, _ = make_api_result("char/planetary_routes.xml")
     result = evelink_pi.parse_planetary_routes(api_result)
     self.assertEqual(result, {
         605707989: {'id': 605707989,
                     'source_id': 1014990361652,
                     'destination_id': 1014990361649,
                     'content': {'type': 2310, 'name': 'Noble Gas'},
                     'quantity': 3000,
                     'path': (1014990361647, 1014990361650, 0, 0, 0),
         },
         605707990: {'id': 605707990,
                     'source_id': 1014990361652,
                     'destination_id': 1014990361647,
                     'content': {'type': 2311, 'name': 'Reactive Gas'},
                     'quantity': 3000,
                     'path': (0, 0, 0, 0, 0),
         },
     })
 def planetary_routes(self, planet_id, api_result=None):
     """Get a list of PI routing entries for a character's planet."""
     return api.APIResult(parse_planetary_routes(api_result.result), api_result.timestamp, api_result.expires)
Exemple #3
0
 def planetary_routes(self, planet_id, api_result=None):
     """Get a list of PI routing entries for a character's planet."""
     return api.APIResult(parse_planetary_routes(api_result.result),
                          api_result.timestamp, api_result.expires)