Skip to main content
Version: 1.x

Variable: presets

const presets: object

Built-in configuration presets.

Type Declaration

ci

ci: object

CI preset — shorter timeouts and debug-friendly defaults for CI pipelines.

Remarks

Reduces ui5WaitTimeout from 30 s to 15 s and controlDiscoveryTimeout from 10 s to 5 s. Enables failure artifact capture. Reduces feedback loop time in CI without sacrificing reliability for well-behaved SAP apps.

Example

import { defineConfig, presets } from 'playwright-praman';
export default defineConfig({ ...presets.ci });

ci.ai?

optional ai?: object

ci.ai.anthropicApiKey?

optional anthropicApiKey?: string

ci.ai.apiKey?

optional apiKey?: string

ci.ai.apiVersion?

optional apiVersion?: string

ci.ai.deployment?

optional deployment?: string

ci.ai.endpoint?

optional endpoint?: string

ci.ai.maxTokens?

optional maxTokens?: number

ci.ai.model?

optional model?: string

ci.ai.provider?

optional provider?: "openai" | "azure-openai" | "anthropic"

ci.ai.temperature?

optional temperature?: number

ci.auth?

optional auth?: object

ci.auth.baseUrl

baseUrl: string

ci.auth.client?

optional client?: string

ci.auth.language?

optional language?: string

ci.auth.password?

optional password?: string

ci.auth.strategy?

optional strategy?: "custom" | "btp-saml" | "basic" | "office365"

Auth strategy for SAP login.

Remarks
  • basic: On-premise form-based login (onprem-strategy)
  • btp-saml: BTP Cloud SAML via IAS (cloud-saml-strategy)
  • office365: Microsoft 365 / Azure AD SSO (office365-strategy)
  • custom: User-provided login function

For API-based, certificate, or multi-tenant auth, see the authentication guide — these are configured programmatically.

ci.auth.username?

optional username?: string

ci.captureFailureArtifacts?

optional captureFailureArtifacts?: boolean

Whether to auto-capture diagnostic artifacts (screenshot, control tree, page context) on test failure.

Remarks

When true (default), the failure artifacts fixture automatically attaches a screenshot (PNG), UI5 control tree snapshot (JSON), and page metadata (JSON) to the test report on any test failure. Set to false to disable.

ci.controlDiscoveryTimeout?

optional controlDiscoveryTimeout?: number

ci.controlTreeCapture?

optional controlTreeCapture?: object

ci.controlTreeCapture.enabled?

optional enabled?: boolean

ci.controlTreeCapture.maxControls?

optional maxControls?: number

ci.controlTreeCapture.maxDepth?

optional maxDepth?: number

ci.defaultMatchSubclasses?

optional defaultMatchSubclasses?: boolean

Default value for matchSubclasses on selectors that don't specify it.

ci.discoveryStrategies?

optional discoveryStrategies?: ("direct-id" | "recordreplay" | "registry")[]

ci.ignoreAutoWaitUrls?

optional ignoreAutoWaitUrls?: string[]

ci.interactionStrategy?

optional interactionStrategy?: "ui5-native" | "dom-first" | "opa5"

ci.logLevel?

optional logLevel?: "error" | "debug" | "warn" | "info" | "verbose"

ci.odataTracing?

optional odataTracing?: object

ci.odataTracing.enabled?

optional enabled?: boolean

ci.odataTracing.urlPatterns?

optional urlPatterns?: string[]

ci.opa5?

optional opa5?: object

ci.opa5.autoWait?

optional autoWait?: boolean

ci.opa5.debug?

optional debug?: boolean

ci.opa5.interactionTimeout?

optional interactionTimeout?: number

ci.preferVisibleControls?

optional preferVisibleControls?: boolean

ci.selectors?

optional selectors?: object

ci.selectors.defaultTimeout?

optional defaultTimeout?: number

Deprecated

Use top-level controlDiscoveryTimeout instead.

ci.selectors.preferVisibleControls?

optional preferVisibleControls?: boolean

ci.selectors.skipStabilityWait?

optional skipStabilityWait?: boolean

ci.skipStabilityWait?

optional skipStabilityWait?: boolean

ci.telemetry?

optional telemetry?: object

ci.telemetry.endpoint?

optional endpoint?: string

ci.telemetry.exporter?

optional exporter?: "otlp" | "azure-monitor" | "jaeger"

ci.telemetry.openTelemetry?

optional openTelemetry?: boolean

ci.telemetry.serviceName?

optional serviceName?: string

ci.ui5WaitTimeout?

optional ui5WaitTimeout?: number

debug

debug: object

Debug preset — verbose logging, longer timeouts for local investigation.

Example

import { defineConfig, presets } from 'playwright-praman';
export default defineConfig({ ...presets.debug });

debug.ai?

optional ai?: object

debug.ai.anthropicApiKey?

optional anthropicApiKey?: string

debug.ai.apiKey?

optional apiKey?: string

debug.ai.apiVersion?

optional apiVersion?: string

debug.ai.deployment?

optional deployment?: string

debug.ai.endpoint?

optional endpoint?: string

debug.ai.maxTokens?

optional maxTokens?: number

debug.ai.model?

optional model?: string

debug.ai.provider?

optional provider?: "openai" | "azure-openai" | "anthropic"

debug.ai.temperature?

optional temperature?: number

debug.auth?

optional auth?: object

debug.auth.baseUrl

baseUrl: string

debug.auth.client?

optional client?: string

debug.auth.language?

optional language?: string

debug.auth.password?

optional password?: string

debug.auth.strategy?

optional strategy?: "custom" | "btp-saml" | "basic" | "office365"

Auth strategy for SAP login.

Remarks
  • basic: On-premise form-based login (onprem-strategy)
  • btp-saml: BTP Cloud SAML via IAS (cloud-saml-strategy)
  • office365: Microsoft 365 / Azure AD SSO (office365-strategy)
  • custom: User-provided login function

For API-based, certificate, or multi-tenant auth, see the authentication guide — these are configured programmatically.

debug.auth.username?

optional username?: string

debug.captureFailureArtifacts?

optional captureFailureArtifacts?: boolean

Whether to auto-capture diagnostic artifacts (screenshot, control tree, page context) on test failure.

Remarks

When true (default), the failure artifacts fixture automatically attaches a screenshot (PNG), UI5 control tree snapshot (JSON), and page metadata (JSON) to the test report on any test failure. Set to false to disable.

debug.controlDiscoveryTimeout?

optional controlDiscoveryTimeout?: number

debug.controlTreeCapture?

optional controlTreeCapture?: object

debug.controlTreeCapture.enabled?

optional enabled?: boolean

debug.controlTreeCapture.maxControls?

optional maxControls?: number

debug.controlTreeCapture.maxDepth?

optional maxDepth?: number

debug.defaultMatchSubclasses?

optional defaultMatchSubclasses?: boolean

Default value for matchSubclasses on selectors that don't specify it.

debug.discoveryStrategies?

optional discoveryStrategies?: ("direct-id" | "recordreplay" | "registry")[]

debug.ignoreAutoWaitUrls?

optional ignoreAutoWaitUrls?: string[]

debug.interactionStrategy?

optional interactionStrategy?: "ui5-native" | "dom-first" | "opa5"

debug.logLevel?

optional logLevel?: "error" | "debug" | "warn" | "info" | "verbose"

debug.odataTracing?

optional odataTracing?: object

debug.odataTracing.enabled?

optional enabled?: boolean

debug.odataTracing.urlPatterns?

optional urlPatterns?: string[]

debug.opa5?

optional opa5?: object

debug.opa5.autoWait?

optional autoWait?: boolean

debug.opa5.debug?

optional debug?: boolean

debug.opa5.interactionTimeout?

optional interactionTimeout?: number

debug.preferVisibleControls?

optional preferVisibleControls?: boolean

debug.selectors?

optional selectors?: object

debug.selectors.defaultTimeout?

optional defaultTimeout?: number

Deprecated

Use top-level controlDiscoveryTimeout instead.

debug.selectors.preferVisibleControls?

optional preferVisibleControls?: boolean

debug.selectors.skipStabilityWait?

optional skipStabilityWait?: boolean

debug.skipStabilityWait?

optional skipStabilityWait?: boolean

debug.telemetry?

optional telemetry?: object

debug.telemetry.endpoint?

optional endpoint?: string

debug.telemetry.exporter?

optional exporter?: "otlp" | "azure-monitor" | "jaeger"

debug.telemetry.openTelemetry?

optional openTelemetry?: boolean

debug.telemetry.serviceName?

optional serviceName?: string

debug.ui5WaitTimeout?

optional ui5WaitTimeout?: number

Example

import { presets } from 'playwright-praman';
console.log(presets.ci.ui5WaitTimeout); // 15000