<%= form.radio_button :contact_made, false,
- checked: set_contact_made_false(@case_contact),
required: true,
class: ["form-check-input", "case-contacts-form-checkbox"] %>
<%= form.label "No", class: "form-check-label",
diff --git a/spec/helpers/case_contacts_helper_spec.rb b/spec/helpers/case_contacts_helper_spec.rb
index d3969a42ac..ce9ad74296 100644
--- a/spec/helpers/case_contacts_helper_spec.rb
+++ b/spec/helpers/case_contacts_helper_spec.rb
@@ -68,23 +68,6 @@
end
end
- describe "#set_contact_made_false" do
- it "returns false if contact_made is true" do
- case_contact = create(:case_contact, contact_made: true)
- expect(helper.set_contact_made_false(case_contact)).to eq(false)
- end
-
- it "returns true if contact_made is false" do
- case_contact = create(:case_contact, contact_made: false)
- expect(helper.set_contact_made_false(case_contact)).to eq(true)
- end
-
- it "returns false if contact_made is nil" do
- case_contact = build(:case_contact, contact_made: nil)
- expect(helper.set_contact_made_false(case_contact)).to eq(false)
- end
- end
-
describe "#show_volunteer_reimbursement" do
before(:each) do
@casa_cases = []
diff --git a/spec/system/case_contacts/new_spec.rb b/spec/system/case_contacts/new_spec.rb
index 75fc4ea7d4..9858dcf139 100644
--- a/spec/system/case_contacts/new_spec.rb
+++ b/spec/system/case_contacts/new_spec.rb
@@ -260,10 +260,11 @@
# default values for other attributes (not from the last contact)
expect(next_case_contact.status).to eq "started"
expect(next_case_contact.miles_driven).to be_zero
- %i[casa_case_id duration_minutes occurred_at contact_made medium_type
+ %i[casa_case_id duration_minutes occurred_at medium_type
want_driving_reimbursement notes].each do |attribute|
expect(next_case_contact.send(attribute)).to be_blank
end
+ expect(next_case_contact.contact_made).to be true
end
it "does not reset referring location" do