MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / test_first_multiple_result

Method test_first_multiple_result

test/ext/test_baked.py:143–149  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

141 eq_(bq(fixture_session()).first(), None)
142
143 def test_first_multiple_result(self):
144 User = self.classes.User
145
146 bq = self.bakery(lambda s: s.query(User.id))
147 bq += lambda q: q.filter(User.name.like("%ed%")).order_by(User.id)
148
149 eq_(bq(fixture_session()).first(), (8,))
150
151 def test_one_or_none_no_result(self):
152 User = self.classes.User

Callers

nothing calls this directly

Calls 8

eq_Function · 0.90
fixture_sessionFunction · 0.90
bakeryMethod · 0.80
queryMethod · 0.45
order_byMethod · 0.45
filterMethod · 0.45
likeMethod · 0.45
firstMethod · 0.45

Tested by

no test coverage detected