|
|
@ -87,13 +87,13 @@ RSpec.describe "Form Check Answers Page" do |
|
|
|
|
|
|
|
|
|
|
|
it "updates the change/answer link when answers get updated" do |
|
|
|
it "updates the change/answer link when answers get updated" do |
|
|
|
visit("/logs/#{empty_case_log.id}/household-needs/check-answers") |
|
|
|
visit("/logs/#{empty_case_log.id}/household-needs/check-answers") |
|
|
|
assert_selector "a", text: /Answer (?!the missing questions)/, count: 4 |
|
|
|
assert_selector "a", text: /Answer (?!the missing questions)/, count: 3 |
|
|
|
assert_selector "a", text: "Change", count: 1 |
|
|
|
assert_selector "a", text: "Change", count: 1 |
|
|
|
visit("/logs/#{empty_case_log.id}/accessibility-requirements") |
|
|
|
visit("/logs/#{empty_case_log.id}/accessibility-requirements") |
|
|
|
check("case-log-accessibility-requirements-housingneeds-c-field") |
|
|
|
check("case-log-accessibility-requirements-housingneeds-c-field") |
|
|
|
click_button("Save and continue") |
|
|
|
click_button("Save and continue") |
|
|
|
visit("/logs/#{empty_case_log.id}/household-needs/check-answers") |
|
|
|
visit("/logs/#{empty_case_log.id}/household-needs/check-answers") |
|
|
|
assert_selector "a", text: /Answer (?!the missing questions)/, count: 3 |
|
|
|
assert_selector "a", text: /Answer (?!the missing questions)/, count: 2 |
|
|
|
assert_selector "a", text: "Change", count: 2 |
|
|
|
assert_selector "a", text: "Change", count: 2 |
|
|
|
expect(page).to have_link("Change", href: "/logs/#{empty_case_log.id}/accessibility-requirements?referrer=check_answers") |
|
|
|
expect(page).to have_link("Change", href: "/logs/#{empty_case_log.id}/accessibility-requirements?referrer=check_answers") |
|
|
|
end |
|
|
|
end |
|
|
|