MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / test_query_cols

Method test_query_cols

test/aaa_profiling/test_orm.py:606–624  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

604 sess.close()
605
606 def test_query_cols(self):
607 Parent = self.classes.Parent
608 self._fixture()
609 sess = fixture_session()
610
611 # warm up cache
612 for attr in [Parent.data1, Parent.data2, Parent.data3, Parent.data4]:
613 attr.__clause_element__()
614
615 @profiling.function_call_count()
616 def go():
617 for i in range(10):
618 q = sess.query(
619 Parent.data1, Parent.data2, Parent.data3, Parent.data4
620 )
621
622 q.all()
623
624 go()
625
626
627class SelectInEagerLoadTest(NoCache, fixtures.MappedTest):

Callers

nothing calls this directly

Calls 4

_fixtureMethod · 0.95
fixture_sessionFunction · 0.90
goFunction · 0.70
__clause_element__Method · 0.45

Tested by

no test coverage detected