Skip to main content

AccessibilitySettings class

A class that is used to set up accessibility validation.

Import statement

from applitools.selenium import AccessibilitySettings

AccessibilitySettings method

Syntax

obj = AccessibilitySettings(level, guidelines_version)

Parameters

level

Type: AccessibilityLevel

The required accessibility level.

guidelines_version

Type: AccessibilityGuidelinesVersion

The required accessibility guide version.

Return value

Type: None

Example

Python

# test suite setup  
suite_config = (Configuration()
.set_accessibility_validation(
AccessibilitySettings(AccessibilityLevel.AAA, AccessibilityGuidelinesVersion.WCAG_2_1))
# ... other configurations
)
#
# Assign the configuration to all newly created Eyes instances
#
eyes = Eyes(runner)
eyes.set_configuration(suite_config)

guidelines_version property

Syntax

obj.guidelines_version  = value
value = obj.guidelines_version

Type: AccessibilityGuidelinesVersion

The accessibility guide version.

level property

Syntax

obj.level  = value
value = obj.level

Type: AccessibilityLevel

The accessibility level.