MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / test_many_prefixes

Method test_many_prefixes

test/orm/test_query.py:5273–5280  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

5271 self.assert_compile(query, expected, dialect=default.DefaultDialect())
5272
5273 def test_many_prefixes(self):
5274 User = self.classes.User
5275 sess = fixture_session()
5276 query = sess.query(User.name).prefix_with("PREFIX_1", "PREFIX_2")
5277 expected = (
5278 "SELECT PREFIX_1 PREFIX_2 users.name AS users_name FROM users"
5279 )
5280 self.assert_compile(query, expected, dialect=default.DefaultDialect())
5281
5282 def test_chained_prefixes(self):
5283 User = self.classes.User

Callers

nothing calls this directly

Calls 4

fixture_sessionFunction · 0.90
prefix_withMethod · 0.80
assert_compileMethod · 0.80
queryMethod · 0.45

Tested by

no test coverage detected