def _make_question_for_today(user, text): category = Category(name='qotd') question = Question(text=text, proposed_by=user, category=category, active=1) question.save() for i in range(4): Answer.objects.create(question=question, correct=i == 1, text='a %d' % i) sched = Schedule(question=question) sched.save() return question
def _make_question_for_today(user, text): category = Category(name='qotd') question = Question(text=text, proposed_by=user, category=category, active=1) question.save() sched = Schedule(question=question) sched.save()