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?: unknown

ci.ai.includeAriaSnapshot?​

optional includeAriaSnapshot?: boolean

Include an aria snapshot in pramanAI.buildContext() output (Playwright 1.60+). On unless set to false.

ci.ai.maxTokens?​

optional maxTokens?: number

ci.ai.model?​

optional model?: string

ci.ai.provider?​

optional provider?: unknown

ci.ai.temperature?​

optional temperature?: number

ci.auth?​

optional auth?: object

ci.auth.baseUrl?​

optional baseUrl?: unknown

ci.auth.client?​

optional client?: string

ci.auth.language?​

optional language?: string

ci.auth.password?​

optional password?: string

ci.auth.strategy?​

optional strategy?: unknown

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.overlays?​

optional overlays?: object

ci.overlays.enabled?​

optional enabled?: boolean

Whether to register the built-in overlay rules.

Remarks​

The built-ins are detect-only — they never dismiss anything. Disable this to register nothing automatically and drive overlays.register() yourself.

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.skipPostFillWait?​

optional skipPostFillWait?: boolean

When true, fill() will not call waitForUI5() after entering text. Useful for rapid sequential fills where intermediate stability waits are unnecessary.

ci.skipStabilityWait?​

optional skipStabilityWait?: boolean

ci.telemetry?​

optional telemetry?: object

ci.telemetry.batchTimeout?​

optional batchTimeout?: number

ci.telemetry.connectionString?​

optional connectionString?: string

Azure Monitor connection string. Required when exporter is 'azure-monitor'.

ci.telemetry.endpoint?​

optional endpoint?: string

ci.telemetry.exporter?​

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

ci.telemetry.maxQueueSize?​

optional maxQueueSize?: number

ci.telemetry.metrics?​

optional metrics?: boolean

ci.telemetry.openTelemetry?​

optional openTelemetry?: boolean

ci.telemetry.protocol?​

optional protocol?: "http" | "grpc"

ci.telemetry.resourceAttributes?​

optional resourceAttributes?: Record<string, string>

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?: unknown

debug.ai.includeAriaSnapshot?​

optional includeAriaSnapshot?: boolean

Include an aria snapshot in pramanAI.buildContext() output (Playwright 1.60+). On unless set to false.

debug.ai.maxTokens?​

optional maxTokens?: number

debug.ai.model?​

optional model?: string

debug.ai.provider?​

optional provider?: unknown

debug.ai.temperature?​

optional temperature?: number

debug.auth?​

optional auth?: object

debug.auth.baseUrl?​

optional baseUrl?: unknown

debug.auth.client?​

optional client?: string

debug.auth.language?​

optional language?: string

debug.auth.password?​

optional password?: string

debug.auth.strategy?​

optional strategy?: unknown

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.overlays?​

optional overlays?: object

debug.overlays.enabled?​

optional enabled?: boolean

Whether to register the built-in overlay rules.

Remarks​

The built-ins are detect-only — they never dismiss anything. Disable this to register nothing automatically and drive overlays.register() yourself.

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.skipPostFillWait?​

optional skipPostFillWait?: boolean

When true, fill() will not call waitForUI5() after entering text. Useful for rapid sequential fills where intermediate stability waits are unnecessary.

debug.skipStabilityWait?​

optional skipStabilityWait?: boolean

debug.telemetry?​

optional telemetry?: object

debug.telemetry.batchTimeout?​

optional batchTimeout?: number

debug.telemetry.connectionString?​

optional connectionString?: string

Azure Monitor connection string. Required when exporter is 'azure-monitor'.

debug.telemetry.endpoint?​

optional endpoint?: string

debug.telemetry.exporter?​

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

debug.telemetry.maxQueueSize?​

optional maxQueueSize?: number

debug.telemetry.metrics?​

optional metrics?: boolean

debug.telemetry.openTelemetry?​

optional openTelemetry?: boolean

debug.telemetry.protocol?​

optional protocol?: "http" | "grpc"

debug.telemetry.resourceAttributes?​

optional resourceAttributes?: Record<string, string>

debug.telemetry.serviceName?​

optional serviceName?: string

debug.ui5WaitTimeout?​

optional ui5WaitTimeout?: number

Example​

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