Skip to content
This repository has been archived by the owner on Nov 3, 2023. It is now read-only.

Commit

Permalink
[dashboard fix]Fix copy_dash unit test (apache#5323)
Browse files Browse the repository at this point in the history
  • Loading branch information
Grace Guo authored and timifasubaa committed Jul 25, 2018
1 parent a71980c commit 29a61c7
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion tests/dashboard_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,12 @@ def test_copy_dash(self, username='admin'):
self.assertEqual(resp['dashboard_title'], 'Copy Of Births')
self.assertEqual(resp['position_json'], orig_json_data['position_json'])
self.assertEqual(resp['metadata'], orig_json_data['metadata'])
self.assertEqual(resp['slices'], orig_json_data['slices'])
# check every attribute in each dashboard's slices list,
# exclude modified and changed_on attribute
for index, slc in enumerate(orig_json_data['slices']):
for key in slc:
if key not in ['modified', 'changed_on']:
self.assertEqual(slc[key], resp['slices'][index][key])

def test_add_slices(self, username='admin'):
self.login(username=username)
Expand Down

0 comments on commit 29a61c7

Please sign in to comment.