feat(playwright/utils): add on first failure as valid trace mode

This commit is contained in:
Stevan Freeborn 2024-02-23 18:35:50 -06:00
parent 8e1384cc2a
commit 7cf41b1107

View file

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
import type { APIRequestContext, Browser, BrowserContext, BrowserContextOptions, Page, LaunchOptions, ViewportSize, Geolocation, HTTPCredentials, Locator, APIResponse, PageScreenshotOptions } from 'playwright-core'; import type { APIRequestContext, APIResponse, Browser, BrowserContext, BrowserContextOptions, Geolocation, HTTPCredentials, LaunchOptions, Locator, Page, PageScreenshotOptions, ViewportSize } from 'playwright-core';
export * from 'playwright-core'; export * from 'playwright-core';
export type ReporterDescription = export type ReporterDescription =
@ -248,7 +248,7 @@ export interface PlaywrightWorkerOptions {
} }
export type ScreenshotMode = 'off' | 'on' | 'only-on-failure'; export type ScreenshotMode = 'off' | 'on' | 'only-on-failure';
export type TraceMode = 'off' | 'on' | 'retain-on-failure' | 'on-first-retry' | 'on-all-retries'; export type TraceMode = 'off' | 'on' | 'retain-on-failure' | 'on-first-retry' | 'on-all-retries' | 'on-first-failure';
export type VideoMode = 'off' | 'on' | 'retain-on-failure' | 'on-first-retry'; export type VideoMode = 'off' | 'on' | 'retain-on-failure' | 'on-first-retry';
export interface PlaywrightTestOptions { export interface PlaywrightTestOptions {
@ -484,4 +484,5 @@ type MergedExpect<List> = Expect<MergedExpectMatchers<List>>;
export function mergeExpects<List extends any[]>(...expects: List): MergedExpect<List>; export function mergeExpects<List extends any[]>(...expects: List): MergedExpect<List>;
// This is required to not export everything by default. See https://github.com/Microsoft/TypeScript/issues/19545#issuecomment-340490459 // This is required to not export everything by default. See https://github.com/Microsoft/TypeScript/issues/19545#issuecomment-340490459
export {}; export { };