-
Notifications
You must be signed in to change notification settings - Fork 125
/
debt-letters.cypress.spec.js
66 lines (58 loc) · 2.32 KB
/
debt-letters.cypress.spec.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
/**
* [TestRail-integrated] Spec for Debt Letters (DL)
* @testrailinfo projectId 7
* @testrailinfo suiteId 8
* @testrailinfo groupId 318
* @testrailinfo runName DL-e2e-List
*/
import mockFeatureToggles from './fixtures/mocks/feature-toggles.json';
import mockDebts from './fixtures/mocks/debts.json';
import mockUser from './fixtures/mocks/mock-user.json';
import mockCopays from './fixtures/mocks/copays.json';
describe.skip('Debt Letters', () => {
beforeEach(() => {
cy.login(mockUser);
cy.intercept('GET', '/v0/feature_toggles?*', mockFeatureToggles).as(
'features',
);
cy.intercept('GET', '/v0/debts', mockDebts).as('debts');
cy.intercept('GET', '/v0/medical_copays', mockCopays);
cy.visit('/');
cy.visit('/manage-va-debt/your-debt');
cy.wait(['@features', '@debts']);
});
it('displays the current debts section and navigates to debt details - C1226', () => {
cy.findByTestId('debts-jumplink').click({ waitForAnimations: true });
cy.get('[data-testclass="debt-details-button"]')
.first()
.click();
cy.get('#debtLetterHistory').should('be.visible');
cy.injectAxeThenAxeCheck();
});
it('displays other va debts', () => {
cy.findByTestId('other-va-copay-body').should('exist');
cy.injectAxeThenAxeCheck();
});
/* eslint-disable @department-of-veterans-affairs/axe-check-required */
// Same display-states below as test above which already had AXE-check.
it('displays download debt letters - C1227', () => {
cy.findByTestId('download-jumplink').click({ waitForAnimations: true });
cy.findByTestId('download-letters-link').click();
cy.get('#downloadDebtLetters').should('be.visible');
});
it('displays how do I pay my VA debt? - C1228', () => {
cy.findByTestId('howto-pay-jumplink').click({ waitForAnimations: true });
cy.get('#howDoIPay').should('be.visible');
});
it('displays how do I get financial help? - C1229', () => {
cy.findByTestId('howto-help-jumplink').click({ waitForAnimations: true });
cy.get('#howDoIGetHelp').should('be.visible');
});
it('displays how do I dispute a debt? - C1230', () => {
cy.findByTestId('howto-dispute-jumplink').click({
waitForAnimations: true,
});
cy.get('#howDoIDispute').should('be.visible');
});
/* eslint-enable @department-of-veterans-affairs/axe-check-required */
});