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

VEBT-1028 - 1995 spool file - modify spool file header benefit type #20329

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
7 changes: 7 additions & 0 deletions app/sidekiq/education_form/forms/va_1995.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ class VA1995 < Base
chapter33: 'CH33',
chapter33Post911: 'CH33',
chapter33FryScholarship: 'CH33',
chapter35: 'CH35',
chapter1606: 'CH1606',
chapter1607: 'CH1607',
transferOfEntitlement: 'TransferOfEntitlement'
Expand All @@ -17,6 +18,12 @@ def school
@applicant.newSchool
end

def header_abbreviated_form_type(header_form_type)
Copy link
Contributor

Choose a reason for hiding this comment

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

@GcioGregg is there a test that covers this method?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@stevenjcumming the fixtures that represent the spool file output cover testing that method. There is at least one fixture/spool file (*.spl) for every entry in the hash used by this method. Thanks.

return 'CH33' if header_form_type.eql?('transferOfEntitlement')

FORM_TYPES[header_form_type&.to_sym]
end

def form_type
FORM_TYPES[@applicant.benefit&.to_sym]
end
Expand Down
4 changes: 2 additions & 2 deletions app/sidekiq/education_form/templates/1995.erb
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<%= parse_with_template_path('header_1995') %>
<% if @applicant.benefitAppliedFor -%>
<%= @applicant.benefitAppliedFor&.titleize %>
<%= header_abbreviated_form_type(@applicant.benefitAppliedFor)%>
<% else -%>
<%= form_benefit %>
<%= header_abbreviated_form_type(@applicant.benefitUpdate)%>
<% end -%>
*START*
VA Form 22-1995
Expand Down
2 changes: 1 addition & 1 deletion spec/fixtures/education_benefits_claims/1995/ch1606.spl
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ TESTER2
1995R


Chapter30
CH30
*START*
VA Form 22-1995
OMB Control #: 2900-0074
Expand Down
39 changes: 39 additions & 0 deletions spec/fixtures/education_benefits_claims/1995/ch1606_baf.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
{
"veteranFullName": {
"first": "Joe",
"last": "Tester2"
},
"veteranSocialSecurityNumber": "223334444",
"veteranAddress": {
"city": "Austin",
"country": "USA",
"postalCode": "73301",
"state": "TX",
"street": "1234 Test St"
},
"sponsorSocialSecurityNumber": "444433322",
"applicantGender": "F",
"dateOfBirth": "1970-01-01",
"email": "[email protected]",
"benefit": "chapter1606",
"benefitUpdate": "chapter1606",
"rudisillReview": "Yes",
"remarks": "remarks",
"programName": "program name",
"privacyAgreementAccepted": true,
"isActiveDuty": true,
"applicantServed": "Yes",
"toursOfDuty": [{
"dateRange": {
"from": "2010-06-26",
"to": "2011-04-10"
},
"serviceBranch": "Army Reserve"
}, {
"dateRange": {
"from": "2010-04-22",
"to": "2011-06-14"
},
"serviceBranch": "navy"
}]
}
81 changes: 81 additions & 0 deletions spec/fixtures/education_benefits_claims/1995/ch1606_baf.spl
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
*INIT*
JOE

TESTER2
223334444
223334444
1995R


CH1606
*START*
VA Form 22-1995
OMB Control #: 2900-0074


REQUEST FOR CHANGE OF BENEFIT, PROGRAM OR PLACE OF TRAINING
FOR VETERANS, SERVICEPERSONS, DEPENDENTS & MEMBERS OF THE SELECTED RESERVE
-------------------------------------

APPLICANT INFORMATION
---------------------

SSN: 223334444 VA File Number: N/A

Sex: F Date of Birth: 1970-01-01

Name: Joe Tester2

Address:
1234 TEST ST
AUSTIN, TX, 73301
USA

Telephone Numbers: Mobile:
Home:

Email Address: [email protected]
Preferred Method of Contact:

Direct Deposit: Type of Account:
Routing/Transit #: Account #:

TYPE AND PROGRAM OF EDUCATION OR TRAINING
-----------------------------------------

Benefit Most Recently Received: Chapter1606

Do you wish to request a 'Rudisill' review?: Yes

Select Another Benefit:

Benefit Being Applied For:

Type of Education or Training:
Education or Career Goal:

New School or Training Establishment:


APPLICANT ACTIVE DUTY SERVICE INFORMATION
-----------------------------------------

Served in the armed forces?: Yes

Are You Now On Active Duty?: YES

Do you have any new periods of service to record since you last applied for
education benefits? YES

Date Entered Date Separated Service Component
2010-06-26 2011-04-10 Army Reserve
2010-04-22 2011-06-14 navy


As an active-duty service member, you have consulted with an Education Service
Officer (ESO) regarding your education program.

Electronically Received by VA: 2017-01-17
Confirmation #: V-EBC-1

*END*
2 changes: 1 addition & 1 deletion spec/fixtures/education_benefits_claims/1995/ch30.spl
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ TESTER
1995R


Chapter1606
CH1606
*START*
VA Form 22-1995
OMB Control #: 2900-0074
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ TESTER
1995R


Chapter1606
CH1606
*START*
VA Form 22-1995
OMB Control #: 2900-0074
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ TESTER
1995R


Chapter35
CH35
*START*
VA Form 22-1995
OMB Control #: 2900-0074
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ TESTER
1995R


Chapter30
CH30
*START*
VA Form 22-1995
OMB Control #: 2900-0074
Expand Down
27 changes: 27 additions & 0 deletions spec/fixtures/education_benefits_claims/1995/ch30_mgi_bill.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"veteranFullName": {
"first": "Joe",
"last": "Tester"
},
"veteranSocialSecurityNumber": "223334444",
"veteranAddress": {
"city": "Austin",
"country": "USA",
"postalCode": "73301",
"state": "TX",
"street": "123 Test St"
},
"applicantServed": "No",
"sponsorSocialSecurityNumber": "444433322",
"applicantGender": "F",
"dateOfBirth": "1970-01-01",
"email": "[email protected]",
"benefit": "chapter33Post911",
"benefitUpdate": "chapter33Post911",
"rudisillReview": "Yes",
"changeAnotherBenefit": "Yes",
"benefitAppliedFor": "chapter30",
"remarks": "remarks",
"programName": "program name",
"privacyAgreementAccepted": true
}
79 changes: 79 additions & 0 deletions spec/fixtures/education_benefits_claims/1995/ch30_mgi_bill.spl
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
*INIT*
JOE

TESTER
223334444
223334444
1995R


CH30
*START*
VA Form 22-1995
OMB Control #: 2900-0074


REQUEST FOR CHANGE OF BENEFIT, PROGRAM OR PLACE OF TRAINING
FOR VETERANS, SERVICEPERSONS, DEPENDENTS & MEMBERS OF THE SELECTED RESERVE
-------------------------------------

APPLICANT INFORMATION
---------------------

SSN: 223334444 VA File Number: N/A

Sex: F Date of Birth: 1970-01-01

Name: Joe Tester

Address:
123 TEST ST
AUSTIN, TX, 73301
USA

Telephone Numbers: Mobile:
Home:

Email Address: [email protected]
Preferred Method of Contact:

Direct Deposit: Type of Account:
Routing/Transit #: Account #:

TYPE AND PROGRAM OF EDUCATION OR TRAINING
-----------------------------------------

Benefit Most Recently Received: Chapter33 Post911

Do you wish to request a 'Rudisill' review?: Yes

Select Another Benefit: Yes

Benefit Being Applied For: Chapter30

Type of Education or Training:
Education or Career Goal:

New School or Training Establishment:


APPLICANT ACTIVE DUTY SERVICE INFORMATION
-----------------------------------------

Served in the armed forces?: No

Are You Now On Active Duty?: N/A

Do you have any new periods of service to record since you last applied for
education benefits? NO

Date Entered Date Separated Service Component


Certification and Signature of Applicant
Signature of Applicant Date

Electronically Received by VA: 2017-01-17
Confirmation #: V-EBC-1

*END*
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ LAST
1995R

SCHOOL NAME
Chapter1606
CH1606
*START*
VA Form 22-1995
OMB Control #: 2900-0074
Expand Down
Loading
Loading