(self)
| 610 | self.assertRaisesRegex(TypeError, msg, B) |
| 611 | |
| 612 | def test_update_layered_implementation(self): |
| 613 | class A(metaclass=abc_ABCMeta): |
| 614 | @abc.abstractmethod |
| 615 | def foo(self): |
| 616 | pass |
| 617 | |
| 618 | class B(A): |
| 619 | pass |
| 620 | |
| 621 | class C(B): |
| 622 | def foo(self): |
| 623 | pass |
| 624 | |
| 625 | C() |
| 626 | |
| 627 | del C.foo |
| 628 | |
| 629 | abc.update_abstractmethods(C) |
| 630 | |
| 631 | msg = "class C without an implementation for abstract method 'foo'" |
| 632 | self.assertRaisesRegex(TypeError, msg, C) |
| 633 | |
| 634 | def test_update_multi_inheritance(self): |
| 635 | class A(metaclass=abc_ABCMeta): |
nothing calls this directly
no test coverage detected