flexpect - v0.21.0
    Preparing search index...

    Options for the toHaveDistanceFrom matcher.

    interface ToHaveDistanceFromOptions {
        tolerance?: number;
        toleranceUnit?: ToleranceUnit;
    }

    Hierarchy (View Summary)

    Index

    Properties

    tolerance?: number

    Allowed 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.

    toleranceUnit?: ToleranceUnit

    Defines the unit in which the tolerance is expressed.

    Defaults to percent if not specified.

    ToleranceUnit.Percent