jest-puppeteer
jest-puppeteer copied to clipboard
jestPuppeteer.resetBrowser() does not clear down service workers
🐛 Bug Report
jestPuppeteer.resetBrowser()
does not seem to destroy any running service workers.
To Reproduce
Steps to reproduce the behavior:
- Setup a file to
beforeEach(async () => {
await jestPuppeteer.resetPage();
await jestPuppeteer.resetBrowser();
});
- Install a service worker in one test.
- In another test, using page.evaluate you can assert a service worker has been installed.
Expected behavior
I would expect resetBrowser
to destroy all running and active service workers.
Link to repl or repo (highly encouraged)
If this is needed to add more context, I can do this. It feels more feature request now i think about it than bug 😄
Run npx envinfo --system --binaries --npmPackages expect-puppeteer,jest-dev-server,jest-environment-puppeteer,jest-puppeteer,spawnd --markdown --clipboard
Paste the results here:
## System:
- OS: macOS 10.14.6
- CPU: (4) x64 Intel(R) Core(TM) i5-4278U CPU @ 2.60GHz
- Memory: 286.91 MB / 8.00 GB
- Shell: 5.3 - /bin/zsh
## Binaries:
- Node: 10.15.0 - ~/.nvm/versions/node/v10.15.0/bin/node
- Yarn: 1.15.2 - ~/.nvm/versions/node/v10.15.0/bin/yarn
- npm: 6.9.0 - ~/.nvm/versions/node/v10.15.0/bin/npm