(self)
| 1447 | self.assertTrue(hash(a) == hash(b)) |
| 1448 | |
| 1449 | def test_isdisjoint_Set(self): |
| 1450 | class MySet(Set): |
| 1451 | def __init__(self, itr): |
| 1452 | self.contents = itr |
| 1453 | def __contains__(self, x): |
| 1454 | return x in self.contents |
| 1455 | def __iter__(self): |
| 1456 | return iter(self.contents) |
| 1457 | def __len__(self): |
| 1458 | return len([x for x in self.contents]) |
| 1459 | s1 = MySet((1, 2, 3)) |
| 1460 | s2 = MySet((4, 5, 6)) |
| 1461 | s3 = MySet((1, 5, 6)) |
| 1462 | self.assertTrue(s1.isdisjoint(s2)) |
| 1463 | self.assertFalse(s1.isdisjoint(s3)) |
| 1464 | |
| 1465 | def test_equality_Set(self): |
| 1466 | class MySet(Set): |
nothing calls this directly
no test coverage detected