Skip to content

Commit

Permalink
Data Fix for handling new response
Browse files Browse the repository at this point in the history
  • Loading branch information
nbowes24 committed Oct 14, 2020
1 parent 86cadc2 commit 57fe98d
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions exporter/collectors/test_collector.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@

def parse_test_response(r, m):
t = []
for i in r.json():
tests = r.json()['data']
for i in tests:
t.append(
{
"test_id": str(i['TestID']),
Expand Down Expand Up @@ -65,7 +66,7 @@ def collect(self):
parsed_tests = parse_test_response(tests, m_test_id_flat_list)

#Exclude test_ids with active maintenance
test_id_list = [i['TestID'] for i in tests.json() if str(i['TestID']) not in m_test_id_flat_list]
test_id_list = [i['test_id'] for i in parsed_tests if str(i['test_id']) not in m_test_id_flat_list]
test_details = []
for i in test_id_list:
test_details.append(
Expand Down

0 comments on commit 57fe98d

Please sign in to comment.