Files
cypress/system-tests/test/uncaught_spec_errors_spec.js
Tyler Biethman 405e7f7ccb chore(webkit): update error stack parsing and related system tests (#23730)
* chore(webkit): update error stack parsing and related system tests

* Adding better comment

* Putting column back. Indexing at 1.

* Let's wait for WebKit fixes to land for this

* Using default name/location values already used in stack enhancing logic

* Incorrect bracket in regex

* Trying without location, as the fake location causes more problems downstream.

* Loosening regex around locations in stack replacement

* Defaulting location sans row/column

* Parsing stack lines for reporter with unique regex

* D'oh

* Making the validation against '<unknown>' more specific

* Don't want a capture group here

* Updating spec_isolation system tests

* Consolidating regex pattern to errors package

* Can just keep this global now

* Simplifying regex. Removing lineAndColumn numbers from unknown locations.

* Updating system test stack regex

* Getting better baseline

* Revert "Updating system test stack regex"

This reverts commit 2b91eff369.

* Forking normalization for webkit to track down diffs

* Ensure line or column are set before rendering in enhanced stack

* Need to be a little more flexible

* Tweaking leading newline detection

* Trying out new composed regex

* Few more tweaks for multiple leading newlines and file locations without function name

* Updating remainderOfStack pattern with proper escaping

* Cleaning up comments

* Filtering native code from absolute path logic

* Rebuild CI after outage
2022-09-12 15:40:12 -05:00

36 lines
766 B
JavaScript

const systemTests = require('../lib/system-tests').default
describe('e2e uncaught errors', () => {
systemTests.setup()
systemTests.it('failing1', {
spec: 'uncaught_synchronous_before_tests_parsed.js',
snapshot: true,
expectedExitCode: 1,
})
systemTests.it('failing2', {
spec: 'uncaught_synchronous_during_hook.cy.js',
snapshot: true,
expectedExitCode: 1,
})
systemTests.it('failing3', {
spec: 'uncaught_during_test.cy.js',
snapshot: true,
expectedExitCode: 3,
})
systemTests.it('failing4', {
spec: 'uncaught_during_hook.cy.js',
snapshot: true,
expectedExitCode: 1,
})
systemTests.it('failing5', {
spec: 'caught_async_sync_test.cy.js',
snapshot: true,
expectedExitCode: 4,
})
})