forked from HHS/TANF-app
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into 2664-ext-msg-2
- Loading branch information
Showing
12 changed files
with
186 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
tdrs-backend/tdpservice/parsers/migrations/0008_alter_datafilesummary_datafile.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# Generated by Django 3.2.15 on 2023-07-20 20:50 | ||
|
||
from django.db import migrations, models | ||
import django.db.models.deletion | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('data_files', '0012_datafile_s3_versioning_id'), | ||
('parsers', '0007_datafilesummary'), | ||
] | ||
|
||
operations = [ | ||
migrations.AlterField( | ||
model_name='datafilesummary', | ||
name='datafile', | ||
field=models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, related_name='summary', to='data_files.datafile'), | ||
), | ||
] |
18 changes: 18 additions & 0 deletions
18
tdrs-backend/tdpservice/parsers/migrations/0009_alter_datafilesummary_status.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
# Generated by Django 3.2.15 on 2023-08-23 12:43 | ||
|
||
from django.db import migrations, models | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
('parsers', '0008_alter_datafilesummary_datafile'), | ||
] | ||
|
||
operations = [ | ||
migrations.AlterField( | ||
model_name='datafilesummary', | ||
name='status', | ||
field=models.CharField(choices=[('Pending', 'Pending'), ('Accepted', 'Accepted'), ('Accepted with Errors', 'Accepted With Errors'), ('Partially Accepted with Errors', 'Partially Accepted'), ('Rejected', 'Rejected')], default='Pending', max_length=50), | ||
), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -244,8 +244,6 @@ describe('SubmissionHistory', () => { | |
expect( | ||
screen.queryByText('Error Reports (In development)') | ||
).toBeInTheDocument() | ||
|
||
expect(screen.queryByText('Currently Unavailable')).toBeInTheDocument() | ||
}) | ||
|
||
it('Shows SSP results when SSP-MOE file type selected', () => { | ||
|
@@ -339,4 +337,63 @@ describe('SubmissionHistory', () => { | |
expect(screen.queryByText('test5.txt')).toBeInTheDocument() | ||
expect(screen.queryByText('test6.txt')).not.toBeInTheDocument() | ||
}) | ||
|
||
it.each([ | ||
'Pending', | ||
'Accepted', | ||
'Accepted with Errors', | ||
'Partially Accepted with Errors', | ||
'Rejected', | ||
null, | ||
])('Shows the submission acceptance status', (status) => { | ||
const state = { | ||
reports: { | ||
files: [ | ||
{ | ||
id: '123', | ||
fileName: 'test1.txt', | ||
fileType: 'TANF', | ||
quarter: 'Q1', | ||
section: 'Active Case Data', | ||
uuid: '123-4-4-321', | ||
year: '2023', | ||
s3_version_id: '321-0-0-123', | ||
createdAt: '12/12/2012 12:12', | ||
submittedBy: '[email protected]', | ||
summary: { | ||
datafile: '123', | ||
status: status, | ||
case_aggregates: { | ||
Oct: { | ||
total: 0, | ||
accepted: 0, | ||
rejected: 0, | ||
}, | ||
Nov: { | ||
total: 0, | ||
accepted: 0, | ||
rejected: 0, | ||
}, | ||
Dec: { | ||
total: 0, | ||
accepted: 0, | ||
rejected: 0, | ||
}, | ||
}, | ||
}, | ||
}, | ||
], | ||
}, | ||
} | ||
|
||
const store = appConfigureStore(state) | ||
const dispatch = jest.fn(store.dispatch) | ||
store.dispatch = dispatch | ||
|
||
setup(store) | ||
|
||
expect(screen.queryByText('Acceptance Status')).toBeInTheDocument() | ||
expect(screen.queryByText('test1.txt')).toBeInTheDocument() | ||
expect(screen.queryByText(status || 'Pending')).toBeInTheDocument() | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters