Skip to content

Commit 10d456f

Browse files
committed
Attach masthead item to document; fixes bootstrap-vue chatty warnings
1 parent 0113cf2 commit 10d456f

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

client/src/components/Masthead/MastheadItem.test.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,19 @@ describe("Masthead.vue", () => {
1616
id: "mytab",
1717
menu: menu,
1818
};
19+
20+
const attachElement = document.createElement("div");
21+
if (document.body) {
22+
document.body.appendChild(attachElement);
23+
}
24+
1925
return mount(MastheadItem, {
2026
propsData: {
2127
tab,
2228
activeTab: active,
2329
},
2430
localVue,
31+
attachTo: attachElement,
2532
});
2633
}
2734

client/tests/jest/jest.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ module.exports = {
6868
// ],
6969

7070
// An array of file extensions your modules use
71-
moduleFileExtensions: ["js", "json", "jsx", "ts", "tsx", "node", "vue"],
71+
moduleFileExtensions: ["js", "json", "vue"],
7272

7373
modulePaths: ["<rootDir>/src/", "<rootDir>/node_modules/", "<rootDir>/tests/"],
7474

0 commit comments

Comments
 (0)