diff --git a/src/layouts/provider-preference/provider-preference.vue b/src/layouts/provider-preference/provider-preference.vue index bf114007..ef852e0a 100644 --- a/src/layouts/provider-preference/provider-preference.vue +++ b/src/layouts/provider-preference/provider-preference.vue @@ -41,11 +41,6 @@ - { vm.setCmsContent(resultMap.cmsContent); - - vm.showSteeringLink = !!vm.$refs[STEERING_MODAL_REF_NAME].ModalBodyText; - if (vm.showSteeringLink) { + if (!!vm.$refs[STEERING_MODAL_REF_NAME].ModalBodyText) { vm.openStateSteeringModal(); } }); @@ -126,13 +116,11 @@ export default { data() { return { selectedProvider: null, - showSteeringLink: false, tpaAcknowledgement: false, rules: { optionRequired: globalRules.OPTION_REQUIRED }, STEERING_MODAL_REF_NAME, - SHOP_PREFERENCE_MODAL_REF_NAME, TPA_RECAL_MODAL_REF_NAME, SITE_FOOTER_REF_NAME }; diff --git a/src/layouts/provider-preference/shop-preference-modal/shop-preference-modal.spec.js b/src/layouts/provider-preference/shop-preference-modal/shop-preference-modal.spec.js deleted file mode 100644 index 226d60bd..00000000 --- a/src/layouts/provider-preference/shop-preference-modal/shop-preference-modal.spec.js +++ /dev/null @@ -1,59 +0,0 @@ -import { shallowMount } from '@vue/test-utils'; -import settleAllPromises from '@/helpers/layout-helper.js'; -import { fetchCmsContentForPage } from '@/helpers/cms-content-helper'; -import { getMountOptions } from '@/helpers/unit-test-helper.js'; -import shopPreferenceModal from '@/layouts/provider-preference/shop-preference-modal/shop-preference-modal.vue'; - -// Mock our module for promises. -jest.mock('@/helpers/layout-helper.js', () => jest.fn()); - -// Mock fetchCmsContentForPage -jest.mock('@/helpers/cms-content-helper', () => ({ - fetchCmsContentForPage: jest.fn(), - setupModalLinks: jest.fn() -})); - -/** @ignore */ -function setupMocks(propsData) { - const mountOptions = getMountOptions({ - router: { - navigate: jest.fn() - } - }); - - mountOptions.propsData = propsData; - - const wrapper = shallowMount( - shopPreferenceModal, - mountOptions - ); - - const apiResponses = {}; - - settleAllPromises.mockImplementation(() => apiResponses); - fetchCmsContentForPage.mockImplementation(() => { }); - - return { wrapper }; -} - -describe('provider-preference.vue', () => { - test('Should display state specific steering modal link when in state with steering language', async () => { - // Arrange - const { wrapper } = setupMocks({ showSteeringLink: true }); - - // Act - - // Test - expect(wrapper.vm.showSteeringLink).toBeTruthy(); - }); - - test('Should not display state specific steering modal link when not in state with steering language', async () => { - // Arrange - const { wrapper } = setupMocks({ showSteeringLink: false }); - - // Act - - // Test - expect(wrapper.vm.showSteeringLink).toBeFalsy(); - }); -}); diff --git a/src/layouts/provider-preference/shop-preference-modal/shop-preference-modal.vue b/src/layouts/provider-preference/shop-preference-modal/shop-preference-modal.vue deleted file mode 100644 index 882c7fb4..00000000 --- a/src/layouts/provider-preference/shop-preference-modal/shop-preference-modal.vue +++ /dev/null @@ -1,111 +0,0 @@ - - - - -