Skip to content

Commit

Permalink
Fix mistake in test code
Browse files Browse the repository at this point in the history
  • Loading branch information
XD-DENG committed Apr 30, 2020
1 parent 26c9d64 commit c85fb20
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/www/test_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -521,7 +521,7 @@ def test_dag_stats(self):
def test_task_stats(self):
resp = self.client.post('task_stats', follow_redirects=True)
self.assertEqual(resp.status_code, 200)
self.assertEqual(set(resp.json().items()[0][1][0].keys()),
self.assertEqual(set(list(resp.json.items())[0][1][0].keys()),
{'state', 'count', 'color'})

def test_task_stats_only_noncompleted(self):
Expand Down Expand Up @@ -1618,7 +1618,7 @@ def test_dag_stats_success(self):
self.login()
resp = self.client.post('dag_stats', follow_redirects=True)
self.check_content_in_response('example_bash_operator', resp)
self.assertEqual(set(resp.json().items()[0][1][0].keys()),
self.assertEqual(set(list(resp.json.items())[0][1][0].keys()),
{'state', 'count', 'color'})

def test_dag_stats_failure(self):
Expand Down

0 comments on commit c85fb20

Please sign in to comment.