Skip to content

Commit 3b175af

Browse files
mmazanec22tahsinaislam
authored andcommitted
Nj 366 dep health ins (#6071)
Change logic to show NJ health insurance question to anyone with dependents, update copy to current year
1 parent 0cedfff commit 3b175af

File tree

6 files changed

+22
-11
lines changed

6 files changed

+22
-11
lines changed

app/controllers/state_file/questions/nj_dependents_health_insurance_controller.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ module Questions
33
class NjDependentsHealthInsuranceController < QuestionsController
44

55
def self.show?(intake)
6-
intake.dependents.any? && intake.has_health_insurance_requirement_exception?
6+
intake.dependents.any?
77
end
88

99
def form_params

app/views/state_file/questions/nj_dependents_health_insurance/edit.html.erb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<% title = t(".title_html", filing_year: current_tax_year) %>
1+
<% title = t(".title_html", current_year: current_tax_year + 1) %>
22

33
<% content_for :page_title, ActionView::Base.full_sanitizer.sanitize(title) %>
44
<% content_for :card do %>

config/locales/en.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3733,8 +3733,8 @@ en:
37333733
edit:
37343734
continue: Click "Continue" if all these people had health insurance.
37353735
coverage_heading: What is health insurance with minimum essential coverage?
3736-
label: 'Check all the people that did NOT have health insurance:'
3737-
title_html: Please tell us which dependents were missing health insurance (<a target=" _blank" rel="noopener noreferrer" href="https://nj.gov/treasury/njhealthinsurancemandate/getinfo.shtml">with minimum essential health coverage</a>) in %{filing_year}.
3736+
label: 'Check all the dependents that do NOT have health insurance:'
3737+
title_html: In %{current_year}, who in your tax household doesn’t have health insurance with <a target=" _blank" rel="noopener noreferrer" href="https://nj.gov/treasury/njhealthinsurancemandate/getinfo.shtml">Minimum Essential Coverage?</a>
37383738
nj_disabled_exemption:
37393739
edit:
37403740
instructions_html: "<p>In New Jersey, you are considered disabled if you have a \"<strong>total and permanent</strong> inability to engage in any substantial gainful activity because of any physical or mental impairment, including blindness.\"</p> \n<p>(This is different from the federal tax definition. New Jersey doesn’t consider your age or your receipt of taxable disability income.)</p>\n"

config/locales/es.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3709,8 +3709,8 @@ es:
37093709
edit:
37103710
continue: Haz clic en "Continuar" si todas estas personas tenían seguro médico.
37113711
coverage_heading: "¿Qué es el seguro de salud con cobertura mínima esencial?"
3712-
label: 'Marca todas las personas que NO tuvieron seguro médico:'
3713-
title_html: Por favor, dinos qué dependientes no tuvieron seguro médico (<a target=" _blank" rel="noopener noreferrer" href="https://nj.gov/treasury/njhealthinsurancemandate/getinfo.shtml">con cobertura médica mínima esencial</a>) en %{filing_year}.
3712+
label: 'Marca a todas las personas dependientes que NO tienen seguro de salud:'
3713+
title_html: ¿En %{current_year}, quién en tu hogar tributario/fiscal no tiene seguro de salud con <a target=" _blank" rel="noopener noreferrer" href="https://nj.gov/treasury/njhealthinsurancemandate/getinfo.shtml">Cobertura Esencial Mínima?</a>
37143714
nj_disabled_exemption:
37153715
edit:
37163716
instructions_html: "<p>En New Jersey, se considera que una persona tiene una discapacidad si tiene una \"incapacidad <strong>total y permanente</strong> para realizar cualquier actividad lucrativa sustancial debido a cualquier discapacidad física o mental, incluida la ceguera.\"</p> \n<p>(Esto es diferente de la definición de impuestos federales. New Jersey no considera tu edad ni la recepción de ingresos por discapacidad imponibles).</p>\n"

spec/controllers/state_file/questions/nj_dependents_health_insurance_controller_spec.rb

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,9 @@
22

33
RSpec.describe StateFile::Questions::NjDependentsHealthInsuranceController do
44
describe ".show?" do
5-
context "when intake has no dependents but would otherwise meet the criteria to show the controller" do
5+
context "when intake has no dependents" do
66
let(:intake) { create :state_file_nj_intake, :df_data_minimal}
77
it "does not show" do
8-
allow_any_instance_of(StateFileNjIntake).to receive(:has_health_insurance_requirement_exception?).and_return(true)
9-
allow_any_instance_of(StateFileNjIntake).to receive(:eligibility_all_members_health_insurance_no?).and_return(true)
108
expect(described_class.show?(intake)).to eq false
119
end
1210
end
@@ -15,10 +13,10 @@
1513
let(:intake) { create :state_file_nj_intake, :df_data_two_deps }
1614

1715
context "and did not have a health insurance requirement exception and all members had health insurance" do
18-
it "does not show" do
16+
it "shows" do
1917
allow_any_instance_of(StateFileNjIntake).to receive(:has_health_insurance_requirement_exception?).and_return(false)
2018
allow_any_instance_of(StateFileNjIntake).to receive(:eligibility_all_members_health_insurance_no?).and_return(false)
21-
expect(described_class.show?(intake)).to eq false
19+
expect(described_class.show?(intake)).to eq true
2220
end
2321
end
2422

spec/features/state_file/nj/complete_intake_spec.rb

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,11 @@ def advance_college_dependents(selection = false)
110110
continue
111111
end
112112

113+
def advance_dependents_health_insurance
114+
page_change_check(I18n.t("state_file.questions.nj_dependents_health_insurance.edit.label"))
115+
continue
116+
end
117+
113118
def advance_medical_expenses(amount: 1000)
114119
page_change_check("You may be able to deduct medical expenses.")
115120
fill_in I18n.t('state_file.questions.nj_medical_expenses.edit.label', filing_year: filing_year), with: amount
@@ -244,6 +249,9 @@ def advance_to_property_tax_page(skip_health_insurance_eligibility: false)
244249
if has_text? I18n.t("state_file.questions.nj_college_dependents_exemption.edit.title")
245250
advance_college_dependents
246251
end
252+
if has_text? I18n.t("state_file.questions.nj_dependents_health_insurance.edit.label")
253+
advance_dependents_health_insurance
254+
end
247255
advance_medical_expenses
248256
end
249257

@@ -279,6 +287,11 @@ def check_xml_results
279287
expect(page).to be_axe_clean
280288
advance_college_dependents
281289
end
290+
291+
page_change_block do
292+
expect(page).to be_axe_clean
293+
advance_dependents_health_insurance
294+
end
282295

283296
page_change_block do
284297
expect(page).to be_axe_clean

0 commit comments

Comments
 (0)