Temporarily exclude menu-modal from unit tests. Remove un-needed code.

This commit is contained in:
bmauger 2022-05-31 16:58:12 -04:00
parent 298da3b24d
commit 07c12f4d8b
6 changed files with 5 additions and 32 deletions

View file

@ -29,6 +29,7 @@ module.exports = {
"!src/common-components/textbox-question/textbox-question.vue", "!src/common-components/textbox-question/textbox-question.vue",
"!src/ux-components/alert\alert.vue", "!src/ux-components/alert\alert.vue",
"!src/helpers/validation-rules.js", "!src/helpers/validation-rules.js",
"!src/common-components/menu-modal/menu-modal.vue",
// END // END
], // ! means exclude from coverage. ], // ! means exclude from coverage.
testMatch: ["**/*.spec.(js|jsx|ts|tsx)|**/__tests__/*.(js|jsx|ts|tsx)"], testMatch: ["**/*.spec.(js|jsx|ts|tsx)|**/__tests__/*.(js|jsx|ts|tsx)"],

View file

@ -3,30 +3,6 @@ import funnelFooter from "./funnel-footer";
describe("funnel-footer.vue", () => { describe("funnel-footer.vue", () => {
it("Should return footer-link class", async () => {
// Act
const r = {
test:"testing",
clientHeight: 10,
offsetHeight: 24,
};
global.document.querySelector = jest.fn().mockImplementation(()=> {
return r;
});
const wrapper = mount(funnelFooter, {
mixins: [mockMixin]
});
// Assert
const link = wrapper.find("a");
// Expect
expect(link.attributes('class')).toContain("footer");
});
it("Should emit ForwardClicked on button click", async () => { it("Should emit ForwardClicked on button click", async () => {
// Act // Act
const wrapper = mount(funnelFooter, { const wrapper = mount(funnelFooter, {

View file

@ -63,9 +63,6 @@ export default {
document.onkeydown = null; document.onkeydown = null;
}, },
computed: { computed: {
height () {
return this.$refs.infoBox.clientHeight;
},
backLink(){ backLink(){
return this.getCmsContent(this.cmsWidgetName, 'BackButtonText'); return this.getCmsContent(this.cmsWidgetName, 'BackButtonText');
}, },

View file

@ -27,7 +27,6 @@ export default {
data() { data() {
return { return {
displayGlobalAlert: false, displayGlobalAlert: false,
headerHeight: 0,
globalAlertMessage: { globalAlertMessage: {
isDismissible: false, isDismissible: false,
messageCopy: "", messageCopy: "",

View file

@ -43,8 +43,8 @@ export default {
self.isActive = false; self.isActive = false;
}); });
myModalEl.addEventListener('show.bs.modal', function (event) { myModalEl.addEventListener('show.bs.modal', function (event) {
self.isActive = true;
self.currentFooterAndHeaderHeight = self.getFooterInfoBoxHeight() + 72; self.currentFooterAndHeaderHeight = self.getFooterInfoBoxHeight() + 72;
self.isActive = true;
}) })
}, },
components: { components: {

View file

@ -5,7 +5,7 @@
ref="theForm" ref="theForm"
v-slot="{ meta }" v-slot="{ meta }"
> >
<div class="page-container-grouped-styles has-footer"> <div class="page-container-grouped-styles">
<funnelHeader cmsWidgetName="FunnelHeaderWidget" /> <funnelHeader cmsWidgetName="FunnelHeaderWidget" />
<vehicleBanner cmsWidgetName="VehicleBannerWidget" :displayGenericVehicleImage=false /> <vehicleBanner cmsWidgetName="VehicleBannerWidget" :displayGenericVehicleImage=false />
<funnelSubHeader cmsWidgetName="FunnelSubHeaderWidget" /> <funnelSubHeader cmsWidgetName="FunnelSubHeaderWidget" />