change page name

This commit is contained in:
Katie Kroell 2023-09-13 15:18:03 -04:00
parent 020bb84704
commit ddb394e0b5
4 changed files with 15 additions and 17 deletions

View file

@ -1,5 +1,5 @@
// Components
import endorsementsPage from '@/layouts/endorsements-page/endorsements-page.vue';
import policyEndorsements from '@/layouts/policy-endorsements/policy-endorsements.vue';
// Supporting Files
import { shallowMount } from '@vue/test-utils';
@ -8,13 +8,11 @@ import navigationScenarios from '@/router/router-constants/navigation-scenarios'
import { createTestingPinia } from '@pinia/testing';
import { useMainStore } from '@/store';
// import { useMainStore } from '@/store/index.js';
describe('endorsementsPage.vue', () => {
describe('policyEndorsements.vue', () => {
describe('Rendering', () => {
test('Should render site header', () => {
// Arrange
const wrapper = shallowMount(endorsementsPage, getMountOptions());
const wrapper = shallowMount(policyEndorsements, getMountOptions());
// Act
const siteHeader = wrapper.findComponent({ ref: 'siteHeader' });
@ -24,7 +22,7 @@ describe('endorsementsPage.vue', () => {
});
test('Should render site subheader', () => {
// Arrange
const wrapper = shallowMount(endorsementsPage, getMountOptions());
const wrapper = shallowMount(policyEndorsements, getMountOptions());
// Act
const siteSubHeader = wrapper.findComponent({ ref: 'siteSubHeader' });
@ -34,7 +32,7 @@ describe('endorsementsPage.vue', () => {
});
test('Should render buttonQuestion component', () => {
// Arrange
const wrapper = shallowMount(endorsementsPage, getMountOptions());
const wrapper = shallowMount(policyEndorsements, getMountOptions());
// Act
const buttonQuestion = wrapper.findComponent({ ref: 'endorsementQuestion' });
@ -44,7 +42,7 @@ describe('endorsementsPage.vue', () => {
});
test('Should render site footer', () => {
// Arrange
const wrapper = shallowMount(endorsementsPage, getMountOptions());
const wrapper = shallowMount(policyEndorsements, getMountOptions());
// Act
const siteFooter = wrapper.findComponent({ ref: 'siteFooter' });
@ -56,7 +54,7 @@ describe('endorsementsPage.vue', () => {
describe('Navigation', () => {
test('Back button clicked triggers navigation', () => {
// Arrange
const wrapper = shallowMount(endorsementsPage, getMountOptions({
const wrapper = shallowMount(policyEndorsements, getMountOptions({
router: {
navigate: jest.fn()
}
@ -72,7 +70,7 @@ describe('endorsementsPage.vue', () => {
});
test('Forward button clicked triggers navigation', () => {
// Arrange
const wrapper = shallowMount(endorsementsPage, getMountOptions({
const wrapper = shallowMount(policyEndorsements, getMountOptions({
router: {
navigate: jest.fn()
}
@ -98,7 +96,7 @@ describe('endorsementsPage.vue', () => {
plugins: [createTestingPinia()]
}
});
const wrapper = shallowMount(endorsementsPage, mountOptions);
const wrapper = shallowMount(policyEndorsements, mountOptions);
// Act
wrapper.vm.forwardButtonAction();

View file

@ -67,7 +67,7 @@ import globalRules from '@/constants/global-rules.js';
import { useMainStore } from '@/store';
export default {
name: 'endorsements-page',
name: 'policy-endorsements',
components: {
siteHeader,
siteSubHeader,

View file

@ -9,7 +9,7 @@ const issPageValues = Object.freeze({
CAPABILITY_QUESTIONS: 'capability-questions',
CONTACT_CONFIRMATION: 'contact-confirmation',
CONTACT_DETAILS: 'contact-details',
ENDORSEMENTS_PAGE: 'endorsements-page',
POLICY_ENDORSEMENTS: 'policy-endorsements',
ESTIMATE: 'estimate',
COVERAGE_STATEMENT: 'coverage-statement',
LICENSE_PLATE_LOOKUP: 'license-plate-lookup',

View file

@ -408,8 +408,8 @@ const routingTable = () => [
},
{
scenario: navigationScenarios.CLICKED_FORWARD_WITH_ENDORSEMENTS,
destinationIssPageValue: issPageValues.ENDORSEMENTS_PAGE
},
destinationIssPageValue: issPageValues.POLICY_ENDORSEMENTS
}
]
},
@ -623,7 +623,7 @@ const routingTable = () => [
]
},
{
issPageValue: issPageValues.ENDORSEMENTS_PAGE,
issPageValue: issPageValues.POLICY_ENDORSEMENTS,
maps: [
{
scenario: navigationScenarios.CLICKED_BACK,
@ -634,7 +634,7 @@ const routingTable = () => [
destinationIssPageValue: issPageValues.VEHICLE_DAMAGE
}
]
},
}
];