OptionaltoleranceAllowed tolerance value.
Must be greater than or equal to 0. Omitting this option defaults to 0,
which will typically cause the assertion to fail or throw an error,
since zero tolerance is allowed.
OptionaltoleranceDefines the unit in which the tolerance is expressed.
Defaults to percent if not specified.
Describes a tolerance value that defines how much deviation from the expected result is acceptable for a matcher.
This type can be reused across different matchers (e.g. alignment, spacing, size comparison) to allow flexible tolerance configuration.
By default, the tolerance is expressed as a percentage, but a pixel-based value can also be used for more precise, fixed-size comparisons.
Example
Example