Browse Source

remove debug line and rubocop

pull/78/head
magicmilo 3 years ago
parent
commit
0d82814fee
  1. 1
      app/helpers/check_answers_helper.rb
  2. 4
      spec/helpers/check_answers_helper_spec.rb
  3. 5
      spec/models/case_log_spec.rb

1
app/helpers/check_answers_helper.rb

@ -28,7 +28,6 @@ module CheckAnswersHelper
def filter_conditional_questions(questions, case_log)
applicable_questions = questions
# puts applicable_questions.count
questions.each do |k, question|
question.fetch("conditional_for", []).each do |conditional_question_key, condition|
if condition_not_met(case_log, k, question, condition)

4
spec/helpers/check_answers_helper_spec.rb

@ -98,9 +98,7 @@ RSpec.describe CheckAnswersHelper do
"hint_text" => "",
"type" => "date",
"check_answer_label" => "Question Label",
"conditional_for" => { "question_2" => %w[12-12-2021] }
}
}
"conditional_for" => { "question_2" => %w[12-12-2021] } } }
end
it "raises an error" do

5
spec/models/case_log_spec.rb

@ -198,10 +198,11 @@ RSpec.describe Form, type: :model do
# Crossover over tests here as injured must be answered as well for no error
it "must be answered if ever served in the forces as a regular" do
expect {
expect do
CaseLog.create!(armed_forces: "Yes - a regular",
armed_forces_active: "Yes",
armed_forces_injured: "Yes")}
armed_forces_injured: "Yes")
end
end
end

Loading…
Cancel
Save