MCPcopy
hub / github.com/django/django / test_fk_fetch_mode_peers

Method test_fk_fetch_mode_peers

tests/raw_query/tests.py:162–167  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

160 self.assertSuccessfulRawQuery(Book, query, books)
161
162 def test_fk_fetch_mode_peers(self):
163 query = "SELECT * FROM raw_query_book"
164 books = list(Book.objects.fetch_mode(FETCH_PEERS).raw(query))
165 with self.assertNumQueries(1):
166 books[0].author
167 books[1].author
168
169 def test_fk_fetch_mode_raise(self):
170 query = "SELECT * FROM raw_query_book"

Callers

nothing calls this directly

Calls 3

fetch_modeMethod · 0.80
assertNumQueriesMethod · 0.80
rawMethod · 0.45

Tested by

no test coverage detected