-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
23 changed files
with
231 additions
and
625 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,65 +1,22 @@ | ||
import 'cypress-file-upload'; | ||
import { testCrossValidation } from '../support/cross-validation.js'; | ||
import { testLoginGovLogin } from '../support/login-gov.js'; | ||
//import { testLogoutGov } from '../support/logout-gov.js'; | ||
import { testValidAccess } from '../support/check-access.js'; | ||
import { testValidEligibility } from '../support/check-eligibility.js'; | ||
import { testValidAuditeeInfo } from '../support/auditee-info.js'; | ||
import { testValidGeneralInfo } from '../support/general-info.js'; | ||
import { testReportIdFound, testReportIdNotFound } from '../support/dissemination-table.js'; | ||
import { testFederalAwards } from '../support/federal-awards.js'; | ||
import { testFileUploadMsg } from '../support/file-uploaded-msg.js'; | ||
|
||
import { testLoginGovLogin } from '../support/login-gov.js'; | ||
import { | ||
testWorkbookAdditionalEINs, | ||
testWorkbookFederalAwards, | ||
testWorkbookAdditionalEINs, | ||
} from '../support/workbook-uploads.js'; | ||
|
||
const LOGIN_TEST_EMAIL_AUDITEE = Cypress.env('LOGIN_TEST_EMAIL_AUDITEE'); | ||
const LOGIN_TEST_PASSWORD_AUDITEE = Cypress.env('LOGIN_TEST_PASSWORD_AUDITEE'); | ||
const LOGIN_TEST_OTP_SECRET_AUDITEE = Cypress.env('LOGIN_TEST_OTP_SECRET_AUDITEE'); | ||
|
||
describe('Additional EINs page', () => { | ||
before(() => { | ||
cy.session('login-session', () => { | ||
cy.visit('/'); | ||
cy.login(); | ||
}); | ||
}); | ||
|
||
it('Additional EINs uploads successfully', () => { | ||
cy.visit('/'); | ||
|
||
cy.url().should('include', '/'); | ||
testLoginGovLogin(); | ||
}); | ||
|
||
cy.get('label[for=check-start-new-submission]').click(); | ||
|
||
cy.get('.usa-button').contains('Accept and start').click(); | ||
|
||
cy.url().should('match', /\/report_submission\/eligibility\/$/); | ||
|
||
testValidEligibility(); | ||
|
||
testValidAuditeeInfo(); | ||
|
||
testValidAccess(); | ||
|
||
// Report should not yet be in the dissemination table | ||
cy.url().then(url => { | ||
const reportId = url.split('/').pop(); | ||
testReportIdNotFound(reportId); | ||
}); | ||
|
||
testValidGeneralInfo(); | ||
|
||
cy.get(".usa-link").contains("Federal Awards").click(); | ||
testWorkbookFederalAwards(false); | ||
|
||
it('Additional EINs uploads successfully', () => { | ||
testFederalAwards(); | ||
cy.get(".usa-link").contains("Additional EINs").click(); | ||
testWorkbookAdditionalEINs(false); | ||
}); | ||
|
||
it('Displays message if file has already been uploaded', () => { | ||
testFileUploadMsg('Edit the Additional EINs'); | ||
}); | ||
|
||
}); | ||
}); |
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 |
---|---|---|
@@ -1,65 +1,22 @@ | ||
import 'cypress-file-upload'; | ||
import { testCrossValidation } from '../support/cross-validation.js'; | ||
import { testLoginGovLogin } from '../support/login-gov.js'; | ||
//import { testLogoutGov } from '../support/logout-gov.js'; | ||
import { testValidAccess } from '../support/check-access.js'; | ||
import { testValidEligibility } from '../support/check-eligibility.js'; | ||
import { testValidAuditeeInfo } from '../support/auditee-info.js'; | ||
import { testValidGeneralInfo } from '../support/general-info.js'; | ||
import { testReportIdFound, testReportIdNotFound } from '../support/dissemination-table.js'; | ||
import { testFederalAwards } from '../support/federal-awards.js'; | ||
import { testFileUploadMsg } from '../support/file-uploaded-msg.js'; | ||
|
||
import { testLoginGovLogin } from '../support/login-gov.js'; | ||
import { | ||
testWorkbookAdditionalUEIs, | ||
testWorkbookFederalAwards, | ||
testWorkbookAdditionalUEIs, | ||
} from '../support/workbook-uploads.js'; | ||
|
||
const LOGIN_TEST_EMAIL_AUDITEE = Cypress.env('LOGIN_TEST_EMAIL_AUDITEE'); | ||
const LOGIN_TEST_PASSWORD_AUDITEE = Cypress.env('LOGIN_TEST_PASSWORD_AUDITEE'); | ||
const LOGIN_TEST_OTP_SECRET_AUDITEE = Cypress.env('LOGIN_TEST_OTP_SECRET_AUDITEE'); | ||
|
||
describe('Additional UEIs page', () => { | ||
before(() => { | ||
cy.session('login-session', () => { | ||
cy.visit('/'); | ||
cy.login(); | ||
}); | ||
}); | ||
|
||
it('Additional UEIs uploads successfully', () => { | ||
cy.visit('/'); | ||
|
||
cy.url().should('include', '/'); | ||
testLoginGovLogin(); | ||
}); | ||
|
||
cy.get('label[for=check-start-new-submission]').click(); | ||
|
||
cy.get('.usa-button').contains('Accept and start').click(); | ||
|
||
cy.url().should('match', /\/report_submission\/eligibility\/$/); | ||
|
||
testValidEligibility(); | ||
|
||
testValidAuditeeInfo(); | ||
|
||
testValidAccess(); | ||
|
||
// Report should not yet be in the dissemination table | ||
cy.url().then(url => { | ||
const reportId = url.split('/').pop(); | ||
testReportIdNotFound(reportId); | ||
}); | ||
|
||
testValidGeneralInfo(); | ||
|
||
cy.get(".usa-link").contains("Federal Awards").click(); | ||
testWorkbookFederalAwards(false); | ||
|
||
it('Additional UEIs uploads successfully', () => { | ||
testFederalAwards(); | ||
cy.get(".usa-link").contains("Additional UEIs").click(); | ||
testWorkbookAdditionalUEIs(false); | ||
}); | ||
|
||
it('Displays message if file has already been uploaded', () => { | ||
testFileUploadMsg('Edit the Additional UEIs'); | ||
}); | ||
|
||
}); | ||
}); |
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 |
---|---|---|
@@ -1,65 +1,22 @@ | ||
import 'cypress-file-upload'; | ||
import { testCrossValidation } from '../support/cross-validation.js'; | ||
import { testLoginGovLogin } from '../support/login-gov.js'; | ||
//import { testLogoutGov } from '../support/logout-gov.js'; | ||
import { testValidAccess } from '../support/check-access.js'; | ||
import { testValidEligibility } from '../support/check-eligibility.js'; | ||
import { testValidAuditeeInfo } from '../support/auditee-info.js'; | ||
import { testValidGeneralInfo } from '../support/general-info.js'; | ||
import { testReportIdFound, testReportIdNotFound } from '../support/dissemination-table.js'; | ||
import { testFederalAwards } from '../support/federal-awards.js'; | ||
import { testFileUploadMsg } from '../support/file-uploaded-msg.js'; | ||
|
||
import { testLoginGovLogin } from '../support/login-gov.js'; | ||
import { | ||
testWorkbookFederalAwards, | ||
testWorkbookFindingsText, | ||
} from '../support/workbook-uploads.js'; | ||
|
||
const LOGIN_TEST_EMAIL_AUDITEE = Cypress.env('LOGIN_TEST_EMAIL_AUDITEE'); | ||
const LOGIN_TEST_PASSWORD_AUDITEE = Cypress.env('LOGIN_TEST_PASSWORD_AUDITEE'); | ||
const LOGIN_TEST_OTP_SECRET_AUDITEE = Cypress.env('LOGIN_TEST_OTP_SECRET_AUDITEE'); | ||
|
||
describe('Audit Findings Text page', () => { | ||
before(() => { | ||
cy.session('login-session', () => { | ||
cy.visit('/'); | ||
cy.login(); | ||
}); | ||
}); | ||
|
||
it('Audit Findings Text uploads successfully', () => { | ||
cy.visit('/'); | ||
|
||
cy.url().should('include', '/'); | ||
testLoginGovLogin(); | ||
}); | ||
|
||
cy.get('label[for=check-start-new-submission]').click(); | ||
|
||
cy.get('.usa-button').contains('Accept and start').click(); | ||
|
||
cy.url().should('match', /\/report_submission\/eligibility\/$/); | ||
|
||
testValidEligibility(); | ||
|
||
testValidAuditeeInfo(); | ||
|
||
testValidAccess(); | ||
|
||
// Report should not yet be in the dissemination table | ||
cy.url().then(url => { | ||
const reportId = url.split('/').pop(); | ||
testReportIdNotFound(reportId); | ||
}); | ||
|
||
testValidGeneralInfo(); | ||
|
||
cy.get(".usa-link").contains("Federal Awards").click(); | ||
testWorkbookFederalAwards(false); | ||
|
||
it('Audit Findings Text uploads successfully', () => { | ||
testFederalAwards(); | ||
cy.get(".usa-link").contains("Federal Awards Audit Findings Text").click(); | ||
testWorkbookFindingsText(false); | ||
}); | ||
|
||
it('Displays message if file has already been uploaded', () => { | ||
testFileUploadMsg('Edit the Federal Awards Audit Findings Text'); | ||
}); | ||
|
||
}); |
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 |
---|---|---|
@@ -1,69 +1,22 @@ | ||
import 'cypress-file-upload'; | ||
import { testCrossValidation } from '../support/cross-validation.js'; | ||
import { testLoginGovLogin } from '../support/login-gov.js'; | ||
//import { testLogoutGov } from '../support/logout-gov.js'; | ||
import { testValidAccess } from '../support/check-access.js'; | ||
import { testValidEligibility } from '../support/check-eligibility.js'; | ||
import { testValidAuditeeInfo } from '../support/auditee-info.js'; | ||
import { testValidGeneralInfo } from '../support/general-info.js'; | ||
import { testReportIdFound, testReportIdNotFound } from '../support/dissemination-table.js'; | ||
import { testFederalAwards } from '../support/federal-awards.js'; | ||
import { testFileUploadMsg } from '../support/file-uploaded-msg.js'; | ||
|
||
import { testLoginGovLogin } from '../support/login-gov.js'; | ||
import { | ||
testWorkbookFederalAwards, | ||
testWorkbookFindingsUniformGuidance, | ||
} from '../support/workbook-uploads.js'; | ||
|
||
const LOGIN_TEST_EMAIL_AUDITEE = Cypress.env('LOGIN_TEST_EMAIL_AUDITEE'); | ||
const LOGIN_TEST_PASSWORD_AUDITEE = Cypress.env('LOGIN_TEST_PASSWORD_AUDITEE'); | ||
const LOGIN_TEST_OTP_SECRET_AUDITEE = Cypress.env('LOGIN_TEST_OTP_SECRET_AUDITEE'); | ||
|
||
describe('Audit Findings page', () => { | ||
before(() => { | ||
cy.session('login-session', () => { | ||
cy.visit('/'); | ||
cy.login(); | ||
}); | ||
}); | ||
|
||
it('Audit Findings uploads successfully', () => { | ||
cy.visit('/'); | ||
|
||
cy.url().should('include', '/'); | ||
testLoginGovLogin(); | ||
}); | ||
|
||
cy.get('label[for=check-start-new-submission]').click(); | ||
|
||
cy.get('.usa-button').contains('Accept and start').click(); | ||
|
||
cy.url().should('match', /\/report_submission\/eligibility\/$/); | ||
|
||
testValidEligibility(); | ||
|
||
testValidAuditeeInfo(); | ||
|
||
testValidAccess(); | ||
|
||
// Report should not yet be in the dissemination table | ||
cy.url().then(url => { | ||
const reportId = url.split('/').pop(); | ||
testReportIdNotFound(reportId); | ||
}); | ||
|
||
testValidGeneralInfo(); | ||
|
||
cy.get('.usa-link').contains("Federal Awards").click(); | ||
testWorkbookFederalAwards(false); | ||
|
||
it('Audit Findings uploads successfully', () => { | ||
testFederalAwards(); | ||
cy.get(".usa-link").contains("Federal Awards Audit Findings").click(); | ||
testWorkbookFindingsUniformGuidance(false); | ||
|
||
}); | ||
|
||
it('Displays message if file has already been uploaded', () => { | ||
testFileUploadMsg('Edit the Federal Awards Audit Findings'); | ||
}); | ||
|
||
}); | ||
|
||
|
||
|
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 |
---|---|---|
@@ -1,66 +1,20 @@ | ||
import 'cypress-file-upload'; | ||
import { testCrossValidation } from '../support/cross-validation.js'; | ||
import { testFederalAwards } from '../support/federal-awards.js'; | ||
import { testFileUploadMsg } from '../support/file-uploaded-msg.js'; | ||
import { testLoginGovLogin } from '../support/login-gov.js'; | ||
//import { testLogoutGov } from '../support/logout-gov.js'; | ||
import { testValidAccess } from '../support/check-access.js'; | ||
import { testValidEligibility } from '../support/check-eligibility.js'; | ||
import { testValidAuditeeInfo } from '../support/auditee-info.js'; | ||
import { testValidGeneralInfo } from '../support/general-info.js'; | ||
import { testPdfAuditReport } from '../support/report-pdf.js'; | ||
|
||
import { | ||
testWorkbookFederalAwards, | ||
} from '../support/workbook-uploads.js'; | ||
|
||
const LOGIN_TEST_EMAIL_AUDITEE = Cypress.env('LOGIN_TEST_EMAIL_AUDITEE'); | ||
const LOGIN_TEST_PASSWORD_AUDITEE = Cypress.env('LOGIN_TEST_PASSWORD_AUDITEE'); | ||
const LOGIN_TEST_OTP_SECRET_AUDITEE = Cypress.env('LOGIN_TEST_OTP_SECRET_AUDITEE'); | ||
import { testPdfAuditReport } from '../support/report-pdf.js'; | ||
|
||
describe('Audit report PDF page', () => { | ||
before(() => { | ||
cy.session('login-session', () => { | ||
cy.visit('/'); | ||
cy.login(); | ||
}); | ||
}); | ||
|
||
it('Audit report PDF uploads successfully', () => { | ||
cy.visit('/'); | ||
|
||
cy.url().should('include', '/'); | ||
testLoginGovLogin(); | ||
}); | ||
|
||
cy.get('label[for=check-start-new-submission]').click(); | ||
|
||
cy.get('.usa-button').contains('Accept and start').click(); | ||
|
||
cy.url().should('match', /\/report_submission\/eligibility\/$/); | ||
|
||
testValidEligibility(); | ||
|
||
testValidAuditeeInfo(); | ||
|
||
testValidAccess(); | ||
|
||
testValidGeneralInfo(); | ||
|
||
cy.get(".usa-link").contains("Federal Awards").click(); | ||
testWorkbookFederalAwards(false); | ||
|
||
it('Audit report PDF uploads successfully', () => { | ||
testFederalAwards(); | ||
cy.get(".usa-link").contains("Audit report PDF").click(); | ||
testPdfAuditReport(false); | ||
testFileUploadMsg('Edit the Audit report PDF'); | ||
}); | ||
|
||
it('Displays message if file has already been uploaded', () => { | ||
cy.visit(`/audit/`); | ||
cy.url().should('match', /\/audit\//); | ||
cy.get(':nth-child(4) > .usa-table > tbody > tr').last().find('td:nth-child(1)>.usa-link').click(); | ||
cy.get('.usa-link').contains('Edit the Audit report PDF').click(); | ||
cy.get('#already-submitted') | ||
.invoke('text') | ||
.then((text) => { | ||
const expectedText = 'A file has already been uploaded for this section. A successful reupload will overwrite your previous submission.'; | ||
expect(text.trim()).to.equal(expectedText); | ||
}); | ||
}); | ||
|
||
}); | ||
}); |
Oops, something went wrong.