MCPcopy
hub / github.com/django/django / test_direct_fk

Method test_direct_fk

tests/migrations/test_state.py:1986–1992  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1984 self.assertRelated(B, [])
1985
1986 def test_direct_fk(self):
1987 A = self.create_model(
1988 "A", foreign_keys=[models.ForeignKey("B", models.CASCADE)]
1989 )
1990 B = self.create_model("B")
1991 self.assertRelated(A, [B])
1992 self.assertRelated(B, [A])
1993
1994 def test_direct_hidden_fk(self):
1995 A = self.create_model(

Callers

nothing calls this directly

Calls 2

create_modelMethod · 0.95
assertRelatedMethod · 0.95

Tested by

no test coverage detected