(self)
| 748 | ) |
| 749 | |
| 750 | def test_compare_fieldless(self): |
| 751 | self.assertTrue(ast.compare(ast.Add(), ast.Add())) |
| 752 | self.assertFalse(ast.compare(ast.Sub(), ast.Add())) |
| 753 | |
| 754 | # test that missing runtime fields is handled in ast.compare() |
| 755 | a1, a2 = ast.Name('a'), ast.Name('a') |
| 756 | self.assertTrue(ast.compare(a1, a2)) |
| 757 | self.assertTrue(ast.compare(a1, a2)) |
| 758 | del a1.id |
| 759 | self.assertFalse(ast.compare(a1, a2)) |
| 760 | del a2.id |
| 761 | self.assertTrue(ast.compare(a1, a2)) |
| 762 | |
| 763 | def test_compare_modes(self): |
| 764 | for mode, sources in ( |
nothing calls this directly
no test coverage detected