Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nj 125 income editing #5288

Draft
wants to merge 52 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
52 commits
Select commit Hold shift + click to select a range
be6ee8c
work in progress - comments on relevant lines
mluedke2 Dec 17, 2024
c4b0a65
Merge branch 'main' into nj-125-income-editing
mluedke2 Dec 17, 2024
b04f37a
one way to hide the unemployment box in nj
mluedke2 Dec 17, 2024
aaaa000
use mailing state instead
mluedke2 Dec 17, 2024
46f7b6d
hide ssa-1099 if nj as well
mluedke2 Dec 17, 2024
8848c80
only show income review if there is something to review
mluedke2 Dec 18, 2024
026f17b
share display condition logic between controller and erb
mluedke2 Dec 18, 2024
2d736b0
Merge branch 'main' into nj-125-income-editing
mluedke2 Dec 18, 2024
89fcc1a
for now just check for state is nj
mluedke2 Dec 19, 2024
bf0927f
Merge branch 'main' into nj-125-income-editing
mluedke2 Dec 19, 2024
60e06ab
remove comment for out of scope
mluedke2 Dec 19, 2024
505c8a8
remove extra comment
mluedke2 Dec 19, 2024
37bdf9c
add e2e tests for income review visual changes
mluedke2 Dec 19, 2024
648e1ae
remove unused imports
mluedke2 Dec 19, 2024
a74cca3
update lucky w2
mluedke2 Dec 20, 2024
c1192ca
nj-specific content
mluedke2 Dec 20, 2024
b0ddea4
dry and condition styling
mluedke2 Dec 20, 2024
850a75d
edit text for box14
mluedke2 Dec 20, 2024
f8465ab
Merge branch 'main' into nj-125-income-editing
mluedke2 Dec 20, 2024
1b36583
update xml for box 14
mluedke2 Dec 20, 2024
71bd8d5
Merge branch 'main' into nj-125-income-editing
mluedke2 Dec 23, 2024
1c6ba7d
sync es
mluedke2 Dec 23, 2024
5ac1833
conform to new format without slashes
mluedke2 Dec 23, 2024
fc59a55
expectations for w2 editing
mluedke2 Dec 23, 2024
496b44f
proper test for assigning box 14 values
mluedke2 Dec 23, 2024
609969e
update more syntax for the no-slash format
mluedke2 Dec 23, 2024
d23cc09
don't use shared tests for nj since it's tested separately
mluedke2 Dec 23, 2024
7bb59ea
missing key in es
mluedke2 Dec 23, 2024
34db50e
normalize strings
mluedke2 Dec 23, 2024
2826eda
Merge branch 'main' into nj-125-income-editing
mluedke2 Dec 23, 2024
ea26a0c
don't catch on conditional strings for unused test
mluedke2 Dec 23, 2024
52a2faf
rearrange translation string keys to not need to add to ignore list
mluedke2 Dec 23, 2024
fd8644f
fix syntax
mluedke2 Dec 23, 2024
92cc4ee
Merge branch 'main' into nj-125-income-editing
mluedke2 Dec 24, 2024
d8ba042
Merge branch 'main' into nj-125-income-editing
mluedke2 Dec 24, 2024
57ceb03
remove unneeded p
mluedke2 Dec 24, 2024
741c76c
Merge branch 'main' into nj-125-income-editing
mluedke2 Dec 26, 2024
0bdbedf
overwrite in model getter instead of just in controller for form, cal…
mluedke2 Dec 26, 2024
471d383
refactor to use one UI_MAX constant, and a method name that explicitl…
mluedke2 Dec 26, 2024
2876f29
fix one of the failing tests
mluedke2 Dec 26, 2024
c28f4cb
fix field name
mluedke2 Dec 27, 2024
a857576
partially undo renaming constants - still keep overwrite function name
mluedke2 Dec 27, 2024
e52ac21
use without slashes or underscores since that is XML format
mluedke2 Dec 27, 2024
341250b
work in progress - roll back to underscores
mluedke2 Dec 30, 2024
aaf6fa3
field name
mluedke2 Dec 30, 2024
1c199d7
use override for ui fields
mluedke2 Dec 30, 2024
b3b80d9
remove two nj checks
mluedke2 Dec 30, 2024
5e6ce7e
remove another nj-specific check
mluedke2 Dec 30, 2024
92dc749
fix i18n health hint
mluedke2 Dec 30, 2024
62f04eb
remove nj-specific key
mluedke2 Dec 30, 2024
4da0204
full i18n key needed for existence check
mluedke2 Dec 30, 2024
de323eb
proper current_state_code
mluedke2 Dec 30, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 16 additions & 10 deletions app/lib/efile/nj/nj1040_calculator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -251,14 +251,12 @@ def line_53c_checkbox
end

def line_59_primary
get_personal_excess(@intake.primary.ssn, :box14_ui_wf_swf, EXCESS_UI_WF_SWF_MAX) +
get_personal_excess(@intake.primary.ssn, :box14_ui_hc_wd, EXCESS_UI_WF_SWF_MAX)
get_personal_excess(@intake.primary.ssn, :box14_ui_wf_swf, EXCESS_UI_WF_SWF_MAX)
end

def line_59_spouse
if @intake.filing_status_mfj?
get_personal_excess(@intake.spouse.ssn, :box14_ui_wf_swf, EXCESS_UI_WF_SWF_MAX) +
get_personal_excess(@intake.spouse.ssn, :box14_ui_hc_wd, EXCESS_UI_WF_SWF_MAX)
get_personal_excess(@intake.spouse.ssn, :box14_ui_wf_swf, EXCESS_UI_WF_SWF_MAX)
end
end

Expand Down Expand Up @@ -437,16 +435,24 @@ def calculate_line_58_irs
@direct_file_data.fed_eic.positive?
end

def get_excess_value(w2, excess_type)
if excess_type == :box14_ui_wf_swf
w2.get_box14_ui_overwrite
else
w2[excess_type]
end
end

def get_personal_excess(ssn, excess_type, threshold)
persons_w2s = @intake.state_file_w2s.all&.select { |w2| w2.employee_ssn == ssn }
return 0 unless persons_w2s.count > 1
return 0 if persons_w2s.any? { |w2| w2[excess_type] && w2[excess_type] > threshold }

total_contribution = 0
return 0 if persons_w2s.any? do |w2|
excess_value = get_excess_value(w2, excess_type)
excess_value && excess_value > threshold
end

persons_w2s.each do |w2|
contribution = w2[excess_type] || 0
total_contribution += contribution
total_contribution = persons_w2s.sum do |w2|
get_excess_value(w2, excess_type) || 0
end

excess_contribution = total_contribution - threshold
Expand Down
14 changes: 10 additions & 4 deletions app/lib/submission_builder/return_w2.rb
Original file line number Diff line number Diff line change
Expand Up @@ -27,20 +27,26 @@ def document

def add_box_14_node(code, node_after_box_14_codes)
field_name = "box14_#{code.downcase}".to_sym
field_as_desc = code.tr '_', '/'
field_as_desc = code.delete '_'

return if !@intake_w2[field_name].present? || !@intake_w2[field_name].positive?
value = if field_name == :box14_ui_wf_swf
@intake_w2.get_box14_ui_overwrite
else
@intake_w2[field_name]
end

return if !value.present? || !value.positive?

existing_xml_node = @xml_node.at_xpath("//OtherDeductionsBenefitsGrp[Desc='#{field_as_desc}']")
if existing_xml_node
existing_xml_node.at('Amt').content = @intake_w2[field_name].round.to_s
existing_xml_node.at('Amt').content = value.round.to_s
else
new_xml_node = Nokogiri::XML::Node.new('OtherDeductionsBenefitsGrp', @xml_node)

desc_node = Nokogiri::XML::Node.new('Desc', @xml_node)
desc_node.content = field_as_desc
amt_node = Nokogiri::XML::Node.new('Amt', @xml_node)
amt_node.content = @intake_w2[field_name].round.to_s
amt_node.content = value.round.to_s

new_xml_node.add_child(desc_node)
new_xml_node.add_child(amt_node)
Expand Down
4 changes: 2 additions & 2 deletions app/models/state_file_base_intake.rb
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,8 @@ def synchronize_df_w2s_to_database
box_14_values[deduction[:other_description]] = deduction[:other_amount]
end
state_file_w2.assign_attributes(
box14_ui_wf_swf: box_14_values['UI/WF/SWF'],
box14_ui_hc_wd: box_14_values['UI/HC/WD'],
box14_ui_wf_swf: box_14_values['UIWFSWF'],
box14_ui_hc_wd: box_14_values['UIHCWD'],
box14_fli: box_14_values['FLI'],
box14_stpickup: box_14_values['STPICKUP'],
employer_ein: direct_file_w2.EmployerEIN,
Expand Down
4 changes: 4 additions & 0 deletions app/models/state_file_w2.rb
Original file line number Diff line number Diff line change
Expand Up @@ -113,4 +113,8 @@ def state_tax_group_xml_node
result = xml_template.at(:W2StateTaxGrp)
result.nil? ? "" : result.to_xml
end

def get_box14_ui_overwrite
read_attribute(:box14_ui_wf_swf) || box14_ui_hc_wd
end
end
2 changes: 1 addition & 1 deletion app/services/state_file/state_information_service.rb
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ def state_intake_class_names
vita_link_es: "",
voucher_form_name: "NJ Voucher Form",
voucher_path: "",
w2_supported_box14_codes: ["UI_WF_SWF", "UI_HC_WD", "FLI"],
w2_supported_box14_codes: ["UI_WF_SWF", "FLI"],
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why isn't this one changing to "UIWFSWF"? Is it possible to change and then we won't need to remove the _ in return_w2.rb submission builder?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh good catch, will do

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I actually decided to end up keeping this, because it all maps back to the DB. It could be renamed, but would require a db migration to rename the field there. (And there were about 70 uses of this throughout the app so I didn't want this diff to grow). And it is only important to not have underscores in the XML alone. If we still want to do that db field name change and related rename I'm not against it but a follow-up would be better in my opinion.

w2_include_local_income_boxes: false
},
ny: {
Expand Down
14 changes: 10 additions & 4 deletions app/views/state_file/questions/income_review/edit.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,12 @@
<% if current_intake.direct_file_data.fed_unemployment > 0 %>
<div class="white-group unemployment" id="form1099gs">
<p class="text--bold spacing-below-0"><%= t(".unemployment_title") %></p>
<% if current_intake.state_file1099_gs.count > 0 %>
<% not_taxed_key = "state_file.questions.income_review.edit.no_info_needed_#{current_state_code}" %>
<% if I18n.exists?(not_taxed_key) %>
<p class="text--grey-bold spacing-above-15 spacing-below-0">
<%= t(not_taxed_key) %>
</p>
<% elsif current_intake.state_file1099_gs.count > 0 %>
<% current_intake.state_file1099_gs.each do |state_1099g| %>
<% recipient = current_intake.send(state_1099g.recipient) %>
<div class="spacing-above-25">
Expand Down Expand Up @@ -72,7 +77,7 @@
<% end %>

<% if current_intake.direct_file_json_data.interest_reports.count > 0 %>
<div class="white-group">
<div class="white-group" id="form1099ints">
<p class="text--bold spacing-below-0"><%= t(".interest_income_title") %></p>
<p class="text--grey-bold spacing-above-15 spacing-below-0">
<%= t(".interest_income_body") %>
Expand All @@ -81,10 +86,11 @@
<% end %>

<% if current_intake.direct_file_data.fed_ssb > 0 || current_intake.direct_file_data.fed_taxable_ssb > 0 %>
<div class="white-group">
<div class="white-group" id="formssa1099s">
<p class="text--bold spacing-below-0"><%= t(".ssa_title") %></p>
<p class="text--grey-bold spacing-above-15 spacing-below-0">
<%= t(".no_info_needed") %>
<% # i18n-tasks-use t("state_file.questions.income_review.edit.no_info_needed") # hint for the i18n linter that, yes, we are using this key (sometimes) %>
<%= t(".no_info_needed_#{current_state_code}", default: :'.no_info_needed') %>
</p>
</div>
<% end %>
Expand Down
23 changes: 18 additions & 5 deletions app/views/state_file/questions/w2/edit.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,24 @@
<p class="spacing-below-25"><%= @w2.employer_name %></p>

<% if @box14_codes.present? %>
<% box14_intro_key = "state_file.questions.w2.edit.box14_intro_#{current_state_code}_html" %>
<% if I18n.exists?(box14_intro_key) %>
<p><%= t(box14_intro_key) %></p>
<% end %>
<fieldset>
<legend class="spacing-below-5"><%= t(".box14_html") %></legend>
<% @box14_codes.each do |code| %>
<div class="form-question spacing-below-25">
<% field_name = "box14_#{code.downcase}" %>
<% value = if code == "UIWFSWF"
@w2.get_box14_ui_overwrite
else
@w2.send(field_name)
end %>
<%= f.vita_min_money_field(
field_name.to_sym,
t(".box14_#{code.downcase}_html"),
options: { value: value },
classes: ["form-width--long"]
) %>
<%= t(".box14_#{code.downcase}_help_text", year: MultiTenantService.statefile.current_tax_year, default: nil) %>
Expand Down Expand Up @@ -46,13 +56,16 @@
<% end %>
</div>

<% if t(".box14_explanation.#{@state_code}_html", default: nil) %>
<% explanation_key = ".box14_explanation_#{current_state_code}_html" %>
<% explanation_text = t(explanation_key, year: MultiTenantService.statefile.current_tax_year, default: nil) %>

<% if explanation_text %>
<div class="reveal spacing-above-35">
<p><button href="#" class="reveal__button"><%= t(".what_is_box14") %></button></p>
<button href="#" class="reveal__button"><%= t(".what_is_box14_#{current_state_code}") %></button>
<div class="reveal__content">
<p class="spacing-below-15">
<%= t(".box14_explanation.#{@state_code}_html", year: MultiTenantService.statefile.current_tax_year) %>
</p>
<p class="spacing-below-15">
<%= explanation_text %>
</p>
</div>
</div>
<% end %>
Expand Down
12 changes: 7 additions & 5 deletions config/locales/en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2871,6 +2871,7 @@ en:
interest_income_body: No additional state info needed
interest_income_title: Interest income (1099-INT)
no_info_needed: No additional state info needed
no_info_needed_nj: This income is not taxed in New Jersey.
retirement_income_title: Retirement income (1099-R)
review_and_edit_state_info: Review and edit state info
ssa_title: Social Security benefits (SSA-1099)
Expand Down Expand Up @@ -3758,14 +3759,14 @@ en:
verification_code_label: Enter the 6-digit code
w2:
edit:
box14_explanation:
md_html: For tax year %{year}, we will only process the <strong>STPICKUP</strong> code, which represents any contributions you made to the state retirement system.
box14_explanation_md_html: For tax year %{year}, we will only process the <strong>STPICKUP</strong> code, which represents any contributions you made to the state retirement system.
mluedke2 marked this conversation as resolved.
Show resolved Hide resolved
box14_explanation_nj_html: 'For this year, we will only need the amounts for <strong>UI/WF/SWF</strong> (may also appear as <strong>"UI/HC/WD"</strong> on your W2) and FLI.<br/><br/><strong>If you do not see these, please leave these fields blank.</strong><br/><br/><strong>Definitions:</strong><br/><br/><strong>UI/WF/SWF</strong> (may also appear as <strong>"UI/HC/WD"</strong> on your W2) represents:<ul><li><strong>UI</strong> refers to unemployment insurance contributions</li><li><strong>WF</strong> and <strong>WD</strong> refer to workforce development partnership fund contributions</li><li><strong>SWF</strong> refers to supplemental workforce fund contributions</li><li><strong>HC</strong> refers to healthcare contributions</li><li><strong>WD</strong> refers to workforce development contributions</li></ul><strong>FLI</strong>: Represents contributions withheld for Family Leave Insurance. Family Leave Insurance (FLI) provides paid leave benefits to bond with a new child, care for a loved one, or cope with domestic/sexual violence. If you have a number for this on your paycheck, it means you have paid into this program and may be eligible to receive cash benefits.<br/><br/>We use the amounts to determine if you might be eligible for a credit.<br/><br/>There may be other information in box 14 - those don''t need to be reported with this tool.'
mluedke2 marked this conversation as resolved.
Show resolved Hide resolved
box14_fli_html: "<strong>FLI</strong>"
box14_html: "<strong>Box 14,</strong> Other"
box14_intro_nj_html: Box 14 will have various letters in it. Those letters all represent program names.<br/><br/>For this year, we will only need the amounts for <strong>UI/WF/SWF</strong> (may also appear as <strong>"UI/HC/WD"</strong> on your W2) <strong>and FLI</strong>.<br/><br/><strong>If you do not see these, please leave these fields blank.</strong><br/><br/>There may be information for other programs in box 14 - those don't need to be reported with this tool.
box14_stpickup_help_text: For %{year}, we will only process the STPICKUP code. If you do not see this code or have other codes in Box 14, please leave it blank.
box14_stpickup_html: "<strong>STPICKUP</strong>"
box14_ui_hc_wd_html: "<strong>UI/HC/WD</strong>"
box14_ui_wf_swf_html: "<strong>UI/WF/SWF</strong>"
box14_ui_wf_swf_html: "<strong>UI/WF/SWF</strong> (This may also appear on your W2 as <strong>UI/HC/WD.</strong>)"
box15_html: "<strong>Box 15,</strong> Employer’s state ID number"
box16_html: "<strong>Box 16,</strong> State wages, tips, etc."
box17_html: "<strong>Box 17,</strong> State income tax"
Expand All @@ -3782,7 +3783,8 @@ en:
state_wages_amt_error: Please enter State wages and tips
state_wages_exceed_amt_error: Total state wages and tips cannot be greater than $%{wages_amount}
wages_amt_error: Total income tax cannot be greater than $%{wages_amount}
what_is_box14: What could be in Box 14?
what_is_box14_md: What could be in Box 14?
what_is_box14_nj: What should I put in Box 14?
waiting_to_load_data:
edit:
subtitle_html: This usually takes a few minutes. Don’t close this page.<br><br> We’ll use your federal tax return information to complete sections of your state return.
Expand Down
12 changes: 7 additions & 5 deletions config/locales/es.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2829,6 +2829,7 @@ es:
interest_income_body: No se necesita información estatal adicional
interest_income_title: Ingresos por intereses (1099-INT)
no_info_needed: No se necesita información estatal adicional
no_info_needed_nj: This income is not taxed in New Jersey.
retirement_income_title: Jubilación (1099-R)
review_and_edit_state_info: Revisar y editar la información estatal
ssa_title: Beneficios del Seguro Social (SSA-1099)
Expand Down Expand Up @@ -3732,14 +3733,14 @@ es:
verification_code_label: Ingresa el código de 6 dígitos
w2:
edit:
box14_explanation:
md_html: Para el año fiscal %{year}, solo procesaremos el código <strong>STPICKUP</strong>, que representa las contribuciones que hiciste al sistema de jubilación estatal.
box14_explanation_md_html: Para el año fiscal %{year}, solo procesaremos el código <strong>STPICKUP</strong>, que representa las contribuciones que hiciste al sistema de jubilación estatal.
box14_explanation_nj_html: 'For this year, we will only need the amounts for <strong>UI/WF/SWF</strong> (may also appear as <strong>"UI/HC/WD"</strong> on your W2) and FLI.<br/><br/><strong>If you do not see these, please leave these fields blank.</strong><br/><br/><strong>Definitions:</strong><br/><br/><strong>UI/WF/SWF</strong> (may also appear as <strong>"UI/HC/WD"</strong> on your W2) represents:<ul><li><strong>UI</strong> refers to unemployment insurance contributions</li><li><strong>WF</strong> and <strong>WD</strong> refer to workforce development partnership fund contributions</li><li><strong>SWF</strong> refers to supplemental workforce fund contributions</li><li><strong>HC</strong> refers to healthcare contributions</li><li><strong>WD</strong> refers to workforce development contributions</li></ul><strong>FLI</strong>: Represents contributions withheld for Family Leave Insurance. Family Leave Insurance (FLI) provides paid leave benefits to bond with a new child, care for a loved one, or cope with domestic/sexual violence. If you have a number for this on your paycheck, it means you have paid into this program and may be eligible to receive cash benefits.<br/><br/>We use the amounts to determine if you might be eligible for a credit.<br/><br/>There may be other information in box 14 - those don''t need to be reported with this tool.'
box14_fli_html: "<strong>FLI</strong>"
box14_html: "<strong>Box 14,</strong> Other"
box14_intro_nj_html: Box 14 will have various letters in it. Those letters all represent program names.<br/><br/>For this year, we will only need the amounts for <strong>UI/WF/SWF</strong> (may also appear as <strong>"UI/HC/WD"</strong> on your W2) <strong>and FLI</strong>.<br/><br/><strong>If you do not see these, please leave these fields blank.</strong><br/><br/>There may be information for other programs in box 14 - those don't need to be reported with this tool.
box14_stpickup_help_text: Para %{year}, solo procesaremos el código STPICKUP. Si no ves este código o tienes otros códigos en Box 14, por favor déjalo en blanco.
box14_stpickup_html: "<strong>STPICKUP</strong>"
box14_ui_hc_wd_html: "<strong>UI/HC/WD</strong>"
box14_ui_wf_swf_html: "<strong>UI/WF/SWF</strong>"
box14_ui_wf_swf_html: "<strong>UI/WF/SWF</strong> (This may also appear on your W2 as <strong>UI/HC/WD.</strong>)"
box15_html: "<strong>Box 15,</strong> Employer’s state ID number"
box16_html: "<strong>Box 16</strong>, State wages, tips, etc."
box17_html: "<strong>Box 17</strong>, State income tax"
Expand All @@ -3756,7 +3757,8 @@ es:
state_wages_amt_error: Ingresa los salarios y propinas estatales
state_wages_exceed_amt_error: El total de salarios e ingresos estatales no puede ser mayor que $%{wages_amount}
wages_amt_error: El impuesto sobre la renta total no puede ser mas de $%{wages_amount}
what_is_box14: "¿Qué podría haber en Box 14?"
what_is_box14_md: "¿Qué podría haber en Box 14?"
what_is_box14_nj: What should I put in Box 14?
waiting_to_load_data:
edit:
subtitle_html: Esto suele tardar unos minutos. No cierres esta página<br><br> Usaremos la información de tu declaración de impuestos federal para completar secciones de tu declaración estatal.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -198,4 +198,4 @@
end
end
end
end
end
74 changes: 74 additions & 0 deletions spec/features/state_file/income_review_spec.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
require "rails_helper"

RSpec.feature "Income Review", active_job: true do
include StateFileIntakeHelper

before do
allow_any_instance_of(Routes::StateFileDomain).to receive(:matches?).and_return(true)
end

context "NJ", :flow_explorer_screenshot, js: true do
def advance_to_data_transfer
visit "/"
click_on "Start Test NJ"
click_on "Get Started", id: "firstCta"
click_on I18n.t("general.continue")
step_through_initial_authentication(contact_preference: :email)
check "Text message"
fill_in "Your phone number", with: "+12025551212"
click_on "Continue"
click_on I18n.t("general.accept")
click_on I18n.t("state_file.questions.terms_and_conditions.edit.accept")
end

it(
"displays review and edit pages with w2s, unemployment, and social security income",
required_schema: "nj"
) do
advance_to_data_transfer

step_through_df_data_transfer("Transfer Zeus box 14")

expect(page).to have_text I18n.t("state_file.questions.income_review.edit.title")
expect(page).to have_text I18n.t("state_file.questions.income_review.edit.w2s_title")

within '#form1099gs' do
expect(page).to have_text I18n.t("state_file.questions.income_review.edit.unemployment_title")
expect(page).to have_text I18n.t("state_file.questions.income_review.edit.no_info_needed_nj")
end

within '#formssa1099s' do
expect(page).to have_text I18n.t("state_file.questions.income_review.edit.ssa_title")
expect(page).to have_text I18n.t("state_file.questions.income_review.edit.no_info_needed_nj")
end

click_on I18n.t("state_file.questions.income_review.edit.review_and_edit_state_info")

# STPICKUP 250
# UIWFSWF 350
# UIHCWD 450
# FLI 550

expect(page).to have_field('state_file_w2_box14_ui_wf_swf', with: '350.0')
expect(page).to have_field('state_file_w2_box14_fli', with: '550.0')
expect(page).to have_field('state_file_w2_employer_state_id_num', with: '12345')
expect(page).to have_field('state_file_w2_state_wages_amount', with: '12345.0')
expect(page).to have_field('state_file_w2_state_income_tax_amount', with: '500.0')
expect(page).to have_button("What should I put in Box 14?")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[PEBBLE] Original tests in review_page_spec test that clicking continue takes you back to the review screen. Since we're removing NJ from those tests, mind putting that check here as well?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

true - will make sure that everything that was tested before is still covered...

end

it "displays with investment income", required_schema: "nj" do
advance_to_data_transfer

step_through_df_data_transfer("Transfer Streep single inv limit")

expect(page).to have_text I18n.t("state_file.questions.income_review.edit.title")
expect(page).to have_text I18n.t("state_file.questions.income_review.edit.w2s_title")

within '#form1099ints' do
expect(page).to have_text I18n.t("state_file.questions.income_review.edit.interest_income_title")
expect(page).to have_text I18n.t("state_file.questions.income_review.edit.no_info_needed")
end
end
end
end
Loading
Loading