Closed ericvsmith closed 7 years ago
@dataclass(slots=True) class C: x: int y: int = 0 c = C(10) self.assertEqual(repr(c), 'C(x=10,y=0)')
Fails with:
Traceback (most recent call last): File "/cygdrive/c/home/eric/local/dataclasses/tst.py", line 627, in test_slots self.assertEqual(repr(c), 'C(x=10,y=0)') AssertionError: "C(x=10,y=<member 'y' of 'C' objects>)" != 'C(x=10,y=0)' - C(x=10,y=<member 'y' of 'C' objects>) + C(x=10,y=0)
Fails with: