| Conditions | 6 |
| Total Lines | 11 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | # -*- coding: utf-8 -*- |
||
| 15 | @staticmethod |
||
| 16 | def test_airports(): |
||
| 17 | fr = flightradar24.Api() |
||
| 18 | airports = fr.get_airports() |
||
| 19 | assert airports['rows'] is not None |
||
| 20 | assert len(airports['rows']) > 100 # Expect more than 100 airports |
||
| 21 | check_jfk = 0 |
||
| 22 | for airport in airports['rows']: |
||
| 23 | if airport['iata'] == "JFK": |
||
| 24 | check_jfk = 1 |
||
| 25 | assert check_jfk == 1 |
||
| 26 | |||
| 72 |