Fix dummy data

This commit is contained in:
Ramon Wenger 2018-11-01 10:56:28 +01:00
parent 7c002dcf36
commit 6e5b829ea1
2 changed files with 3 additions and 3 deletions

View File

@ -755,7 +755,7 @@ class Command(BaseCommand):
for objective_group_idx, objective_group_entry in enumerate(objective_group_data):
factory_params = self.filter_data(objective_group_entry, 'objectives')
objective_group = ObjectiveGroupFactory.create(module=module,
user=None,
owner=None,
**factory_params)
default_objectives = [{} for i in range(0, 4)]

View File

@ -12,10 +12,10 @@ class ObjectiveGroupFactory(factory.django.DjangoModelFactory):
class Meta:
model = ObjectiveGroup
title = factory.Iterator(['Gesellschaft', 'Sprache und Kommunikation'])
title = factory.Iterator([ObjectiveGroup.LANGUAGE_COMMUNICATION, ObjectiveGroup.SOCIETY])
module = factory.SubFactory(ModuleFactory)
user = factory.Iterator(get_user_model().objects.all())
owner = factory.Iterator(get_user_model().objects.all())
class ObjectiveFactory(factory.django.DjangoModelFactory):