in pulseapi/tests.py [0:0]
def setup_entries(test, creator_users):
test.entries = []
test.creators = []
for i in range(2):
entry = EntryFactory()
entry.save()
creators = [BasicUserProfileFactory(use_custom_name=True)]
if creator_users and len(creator_users) > i:
# If we were passed in users, create a creator attached to a user profile
for user in creator_users:
creators.append(user.profile)
for creator in creators:
creator.save()
# Connect the creator with the entry
EntryCreatorFactory(entry=entry, profile=creator)
test.creators.extend(creators)
test.entries.append(entry)