I have a unique scenario where I need to mock the return value of a custom plugin without importing it directly into my test. By creating a mock function for the plugin, I can easily achieve this goal. However, I am unsure how to change the return value of the plugin within the test.
const $mq = () => {};
wrapper = shallowMount(Component, {
//...
mocks: {
$mq
}
//...
});
Test
it ('Test description', () => {
wrapper.vm.$mq = () => true; // HOW TO MOCK PLUGIN RETURNS???
});