(self)
| 774 | ) |
| 775 | |
| 776 | def test_compare_attributes_option(self): |
| 777 | def parse(a, b): |
| 778 | return ast.parse(a), ast.parse(b) |
| 779 | |
| 780 | a, b = parse("2 + 2", "2+2") |
| 781 | self.assertTrue(ast.compare(a, b)) |
| 782 | self.assertTrue(ast.compare(a, b, compare_attributes=False)) |
| 783 | self.assertFalse(ast.compare(a, b, compare_attributes=True)) |
| 784 | |
| 785 | def test_compare_attributes_option_missing_attribute(self): |
| 786 | # test that missing runtime attributes is handled in ast.compare() |
nothing calls this directly
no test coverage detected