MCPcopy Index your code
hub / github.com/sqlalchemy/sqlalchemy / test_ai_Bi

Method test_ai_Bi

test/orm/test_instrumentation.py:97–117  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

95 eq_(inits, [(B, "init", B), (A, "__init__")])
96
97 def test_ai_Bi(self):
98 inits = []
99
100 class A:
101 def __init__(self):
102 inits.append((A, "__init__"))
103
104 class B(A):
105 def __init__(self):
106 inits.append((B, "__init__"))
107 super().__init__()
108
109 self.register(B, inits)
110
111 A()
112 eq_(inits, [(A, "__init__")])
113
114 del inits[:]
115
116 B()
117 eq_(inits, [(B, "init", B), (B, "__init__"), (A, "__init__")])
118
119 def test_Ai_bi(self):
120 inits = []

Callers

nothing calls this directly

Calls 4

registerMethod · 0.95
eq_Function · 0.90
AClass · 0.70
BClass · 0.70

Tested by

no test coverage detected