MCPcopy
hub / github.com/django/django / setUpTestData

Method setUpTestData

tests/admin_ordering/tests.py:106–114  ·  view source on GitHub ↗
(cls)

Source from the content-addressed store, hash-verified

104
105 @classmethod
106 def setUpTestData(cls):
107 cls.band = Band.objects.create(name="Aerosmith", bio="", rank=3)
108 Song.objects.bulk_create(
109 [
110 Song(band=cls.band, name="Pink", duration=235),
111 Song(band=cls.band, name="Dude (Looks Like a Lady)", duration=264),
112 Song(band=cls.band, name="Jaded", duration=214),
113 ]
114 )
115
116 def test_default_ordering(self):
117 """

Callers

nothing calls this directly

Calls 3

bulk_createMethod · 0.80
SongClass · 0.70
createMethod · 0.45

Tested by

no test coverage detected