Closed kartikwatwani closed 3 years ago
Before every use of a browser property during tests, you'll need to mock it (for example using the expect syntax). See https://lusito.github.io/mockzilla-webextension/browser.html#solution
I learned how to use this module. Thanks for this!
I am using
browser.runtime
in my code then in the test file I am using mockzilla as follows:But when I am running tests I am getting the following error:
What should I do to run my tests if I use
browser.runtime
. If I wish to implementbrowser.runtime
myself can you guide me on it?Update: I also tried
browser.tabs
but that is also not working.