MCPcopy Create free account
hub / github.com/pytest-dev/pytest / A

Class A

testing/test_assertrewrite.py:692–700  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

690 def test_assert_raising__bool__in_comparison(self) -> None:
691 def f() -> None:
692 class A:
693 def __bool__(self):
694 raise ValueError(42)
695
696 def __lt__(self, other):
697 return A()
698
699 def __repr__(self):
700 return "<MY42 object>"
701
702 def myany(x) -> bool:
703 return False

Callers 2

__lt__Method · 0.70
fMethod · 0.70

Calls

no outgoing calls

Tested by 2

__lt__Method · 0.56
fMethod · 0.56