CASH-376 unit test fix
This commit is contained in:
parent
501e16303f
commit
3ccb294a36
1 changed files with 2 additions and 10 deletions
|
|
@ -81,16 +81,6 @@ jest.mock(
|
||||||
})
|
})
|
||||||
);
|
);
|
||||||
|
|
||||||
jest.mock(
|
|
||||||
"@/layouts/service-location/mobile-location-modal-questions/mobile-location-modal-questions.vue",
|
|
||||||
() => ({
|
|
||||||
isMobileAddressComplete: jest.fn(() => {
|
|
||||||
return true;
|
|
||||||
}),
|
|
||||||
openModal: jest.fn(),
|
|
||||||
})
|
|
||||||
);
|
|
||||||
|
|
||||||
jest.spyOn(baseMixin.methods, "getZipCodeData").mockImplementation((serviceZipCode) => {
|
jest.spyOn(baseMixin.methods, "getZipCodeData").mockImplementation((serviceZipCode) => {
|
||||||
return new Promise((resolve) => {
|
return new Promise((resolve) => {
|
||||||
let mockContainsMilitaryBase = false;
|
let mockContainsMilitaryBase = false;
|
||||||
|
|
@ -1443,5 +1433,7 @@ function setupMocks({ mountOptionsMockData = {} }) {
|
||||||
const mountOptions = getMountOptions(mountOptionsMockData);
|
const mountOptions = getMountOptions(mountOptionsMockData);
|
||||||
const wrapper = shallowMount(serviceLocation, mountOptions);
|
const wrapper = shallowMount(serviceLocation, mountOptions);
|
||||||
wrapper.vm.setCmsContent = baseMixin.methods.setCmsContent;
|
wrapper.vm.setCmsContent = baseMixin.methods.setCmsContent;
|
||||||
|
wrapper.vm.$refs.mobileLocationQuestions.isMobileAddressComplete = jest.fn();
|
||||||
|
wrapper.vm.$refs.mobileLocationQuestions.openModal = jest.fn();
|
||||||
return { wrapper, apiPromise };
|
return { wrapper, apiPromise };
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue