MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / test_set_strat_col

Method test_set_strat_col

test/orm/test_options.py:226–235  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

224 )
225
226 def test_set_strat_col(self):
227 User = self.classes.User
228
229 l1 = Load(User)
230 l2 = l1.defer(User.name)
231 s = fixture_session()
232 q1 = s.query(User).options(l2)
233 attr = q1._compile_context().attributes
234
235 eq_(attr[("loader", self._make_path([User, "name"]))], l2.context[0])
236
237
238class OfTypePathingTest(PathTest, QueryTest):

Callers

nothing calls this directly

Calls 8

LoadClass · 0.90
fixture_sessionFunction · 0.90
eq_Function · 0.90
deferMethod · 0.80
_compile_contextMethod · 0.80
_make_pathMethod · 0.80
optionsMethod · 0.45
queryMethod · 0.45

Tested by

no test coverage detected