@cypress/code-coverage
Advanced tools
Comparing version 3.12.39 to 3.12.40
{ | ||
"name": "@cypress/code-coverage", | ||
"version": "3.12.39", | ||
"version": "3.12.40", | ||
"description": "Saves the code coverage collected during Cypress tests", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -69,4 +69,9 @@ /// <reference types="cypress" /> | ||
const saveCoverageObject = (win) => { | ||
// if application code has been instrumented, the app iframe "window" has an object | ||
const applicationSourceCoverage = win?.__coverage__ | ||
// if the application code has been instrumented, then the app iframe "win.__coverage__" will be available, | ||
// in addition, accessing win.__coverage__ can throw when testing cross-origin code, | ||
// because we don't control the cross-origin code, we can safely return | ||
let applicationSourceCoverage | ||
try { | ||
applicationSourceCoverage = win?.__coverage__ | ||
} catch {} | ||
if (!applicationSourceCoverage) { | ||
@@ -73,0 +78,0 @@ return |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
66030
1064