OLD | NEW |
| 1 #!/usr/bin/env python |
1 # Copyright 2016 The Chromium Authors. All rights reserved. | 2 # Copyright 2016 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 4 # found in the LICENSE file. |
4 """Tests for dexdiffer.""" | 5 """Tests for dexdiffer.""" |
5 | 6 |
6 import dexdiffer | 7 import dexdiffer |
7 import json | 8 import json |
8 import unittest | 9 import unittest |
9 | 10 |
10 | 11 |
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
177 self.assertDeepEqual(actual, expected) | 178 self.assertDeepEqual(actual, expected) |
178 | 179 |
179 def assertDeepEqual(self, actual, expected): | 180 def assertDeepEqual(self, actual, expected): |
180 # Only designed to work for json-able types | 181 # Only designed to work for json-able types |
181 a = json.dumps(actual, sort_keys=True) | 182 a = json.dumps(actual, sort_keys=True) |
182 e = json.dumps(expected, sort_keys=True) | 183 e = json.dumps(expected, sort_keys=True) |
183 self.assertEqual(a, e) | 184 self.assertEqual(a, e) |
184 | 185 |
185 if __name__ == '__main__': | 186 if __name__ == '__main__': |
186 unittest.main() | 187 unittest.main() |
OLD | NEW |