def test_empty_trip_id_2(self):
feed = {'header': {'timestamp': 1},
'entity': [{'id': '000022',
'type': 'vehicle_update',
'vehicle': {'current_stop_sequence': 0,
'stop_id': '',
'current_status': 'IN_TRANSIT_TO',
'timestamp': 0,
'trip': {'route_id': '',
'trip_id': '',
'start_date': ''}}}]}
# noinspection PyUnresolvedReferences
with pytest.warns(UserWarning):
feed = gt.correct(feed)
assert len(feed['entity']) == 0
评论列表
文章目录