@@ -239,27 +239,30 @@ module Admin
239239 expect ( questionnaire . questions [ 1 ] . description [ "en" ] ) . to eq ( form_params [ "questions" ] [ "1" ] [ "description" ] [ "en" ] )
240240 expect ( questionnaire . questions [ 1 ] . question_type ) . to eq ( "long_answer" )
241241 expect ( questionnaire . questions [ 1 ] . max_characters ) . to eq ( 100 )
242- expect ( questionnaire . questions [ 2 ] . answer_options [ 1 ] [ "body" ] [ "en" ] ) . to eq ( form_params [ "questions" ] [ "2" ] [ "answer_options" ] [ "1" ] [ "body" ] [ "en" ] )
242+ expect ( questionnaire . questions [ 1 ] . published_at ) . not_to be_nil
243243
244244 expect ( questionnaire . questions [ 2 ] . question_type ) . to eq ( "single_option" )
245245 expect ( questionnaire . questions [ 2 ] . max_choices ) . to be_nil
246246 expect ( questionnaire . questions [ 2 ] . max_characters ) . to eq ( 0 )
247-
248- expect ( questionnaire . questions [ 3 ] . question_type ) . to eq ( "multiple_option" )
247+ expect ( questionnaire . questions [ 2 ] . answer_options [ 1 ] [ "body" ] [ "en" ] ) . to eq ( form_params [ "questions" ] [ "2" ] [ "answer_options" ] [ "1" ] [ "body" ] [ "en" ] )
248+ expect ( questionnaire . questions [ 2 ] . published_at ) . not_to be_nil
249249 expect ( questionnaire . questions [ 2 ] . answer_options [ 0 ] . free_text ) . to eq ( false )
250250 expect ( questionnaire . questions [ 2 ] . max_choices ) . to be_nil
251251
252252 expect ( questionnaire . questions [ 3 ] . question_type ) . to eq ( "multiple_option" )
253253 expect ( questionnaire . questions [ 3 ] . answer_options [ 0 ] . free_text ) . to eq ( true )
254254 expect ( questionnaire . questions [ 3 ] . max_choices ) . to eq ( 2 )
255+ expect ( questionnaire . questions [ 3 ] . published_at ) . not_to be_nil
255256
256257 expect ( questionnaire . questions [ 4 ] . question_type ) . to eq ( "matrix_single" )
257258 expect ( questionnaire . questions [ 4 ] . answer_options [ 0 ] . free_text ) . to eq ( true )
258259 expect ( questionnaire . questions [ 4 ] . matrix_rows [ 0 ] . body [ "en" ] ) . to eq ( form_params [ "questions" ] [ "4" ] [ "matrix_rows" ] [ "0" ] [ "body" ] [ "en" ] )
260+ expect ( questionnaire . questions [ 4 ] . published_at ) . not_to be_nil
259261
260262 expect ( questionnaire . questions [ 5 ] . question_type ) . to eq ( "matrix_multiple" )
261263 expect ( questionnaire . questions [ 5 ] . answer_options [ 0 ] . free_text ) . to eq ( true )
262264 expect ( questionnaire . questions [ 5 ] . matrix_rows [ 0 ] . body [ "en" ] ) . to eq ( form_params [ "questions" ] [ "5" ] [ "matrix_rows" ] [ "0" ] [ "body" ] [ "en" ] )
265+ expect ( questionnaire . questions [ 5 ] . published_at ) . not_to be_nil
263266 end
264267 end
265268
0 commit comments