mirror of
https://github.com/bringout/oca-ocb-core.git
synced 2026-04-22 02:32:07 +02:00
vanilla 16.0
This commit is contained in:
parent
8c653da57a
commit
f0ee375081
156 changed files with 10614 additions and 55980 deletions
|
|
@ -44,6 +44,7 @@ class TestSurveyInternals(common.TestSurveyCommon):
|
|||
self.assertEqual(fourth_attempt['attempts_count'], 4)
|
||||
|
||||
@freeze_time("2020-02-15 18:00")
|
||||
@users('survey_manager')
|
||||
def test_answer_display_name(self):
|
||||
""" The "display_name" field in a survey.user_input.line is a computed field that will
|
||||
display the answer label for any type of question.
|
||||
|
|
@ -67,7 +68,7 @@ class TestSurveyInternals(common.TestSurveyCommon):
|
|||
self.assertEqual(question_answer.display_name, '2020-02-15')
|
||||
elif question.question_type == 'datetime':
|
||||
question_answer = self._add_answer_line(question, user_input, fields.Datetime.now())
|
||||
self.assertEqual(question_answer.display_name, '2020-02-15 18:00:00')
|
||||
self.assertEqual(question_answer.display_name, '2020-02-15 19:00:00')
|
||||
elif question.question_type == 'simple_choice':
|
||||
question_answer = self._add_answer_line(question, user_input, question.suggested_answer_ids[0].id)
|
||||
self.assertEqual(question_answer.display_name, 'SChoice0')
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue