Ways to resolve tooltip warnings in test cases in Vue Test Utils
P粉293341969
2023-08-26 19:41:24
<p>When using bootstrap-vue's v-b-tooltip.hover, a warning always appears in the unit test: </p><p><strong>[BootstrapVue warn]: tooltip - the provided target is not valid HTML element. </strong></p>
I found that using attachTo: createContainer() when defining componentData can solve the problem. At the same time, whenever the wrapper is redefined, it must also be redefined.