Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@web/test-runner-chrome

Package Overview
Dependencies
Maintainers
6
Versions
93
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@web/test-runner-chrome - npm Package Compare versions

Comparing version 0.5.5 to 0.5.6

6

CHANGELOG.md
# @web/test-runner-chrome
## 0.5.6
### Patch Changes
- 4a6b9c2: make coverage work in watch mode
## 0.5.5

@@ -4,0 +10,0 @@

22

dist/chromeLauncher.js

@@ -27,2 +27,5 @@ "use strict";

const inactivePages = [];
// puppeteer does not indicate whether coverage is enabled, so we track it here
const pagesWithCoverageEnabled = new WeakSet();
const cachedCoverage = new WeakMap();
let browser;

@@ -62,5 +65,2 @@ let debugBrowser = undefined;

page = await browser.newPage();
if (config.coverage) {
await page.coverage.startJSCoverage();
}
}

@@ -70,2 +70,7 @@ else {

}
if (config.coverage && !pagesWithCoverageEnabled.has(page)) {
pagesWithCoverageEnabled.add(page);
cachedCoverage.delete(page);
await page.coverage.startJSCoverage();
}
activePages.set(session.id, page);

@@ -83,3 +88,12 @@ await page.setViewport({ height: 600, width: 800 });

getTestCoverage() {
return Promise.all(inactivePages.map(page => getPageCoverage(config, testFiles, page)));
return Promise.all(inactivePages.map(page => {
if (pagesWithCoverageEnabled.has(page)) {
pagesWithCoverageEnabled.delete(page);
return getPageCoverage(config, testFiles, page).then(coverage => {
cachedCoverage.set(page, coverage);
return coverage;
});
}
return cachedCoverage.get(page);
}));
},

@@ -86,0 +100,0 @@ async startDebugSession(session, url) {

2

package.json
{
"name": "@web/test-runner-chrome",
"version": "0.5.5",
"version": "0.5.6",
"publishConfig": {

@@ -5,0 +5,0 @@ "access": "public"

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc