This repository was archived by the owner on Sep 11, 2025. It is now read-only.

Description
Is your feature request related to a problem? Please describe.
This is specifically a problem for libraries intercepting jest-environment-* libraries to create integrations.
In this specific line:
async handleTestEvent(event: Event) {
const { browserName } = this._config
const { collectCoverage, haveSkippedTests } = this._jestPlaywrightConfig
const browserType = getBrowserType(browserName)
//...
we're not calling super.handleTestEvent which would help said libraries.
Describe the solution you'd like
Change to above to
async handleTestEvent(event: Event) {
// calling `super.handleTestEvent` in case it's there
if (super.handleTestEvent) {
await super.handleTestEvent.apply(this, arguments)
}
const { browserName } = this._config
const { collectCoverage, haveSkippedTests } = this._jestPlaywrightConfig
const browserType = getBrowserType(browserName)
//...
This would help:
- in case
jest-environment-* libraries decide to implement their own handleTestEvent
- with Datadog's test visibility library, making it easier to integrate both libraries
Describe alternatives you've considered
Calling super.handleTestEvent seems low risk, so no alternatives were considered.