Skip to main content

TestResults class

Encapsulates the results of a visual test, including summary information and checkpoint-specific details. An object of this class is returned by the close method upon test completion.

Import statement

import com.applitools.eyes.android.common.TestResults;

getAccessibilityStatus method

Syntax

SessionAccessibilityStatus value = result.getAccessibilityStatus();

Parameters

This method does not take any parameters.

Return value

Type: SessionAccessibilityStatus

Remarks

For more information about the Contrast advisor feature see Contrast advisor.

getAppName method

Syntax

String value = result.getAppName();

Parameters

This method does not take any parameters.

Return value

Type: String

The application name.

getMatches method

Syntax

int value = result.getMatches();

Parameters

This method does not take any parameters.

Return value

Type: int

getMismatches method

Syntax

int value = result.getMismatches();

Parameters

This method does not take any parameters.

Return value

Type: int

getMissing method

Syntax

int value = result.getMissing();

Parameters

This method does not take any parameters.

Return value

Type: int

getName method

Syntax

String value = result.getName();

Parameters

This method does not take any parameters.

Return value

Type: String

The name of the test.

getStatus method

Syntax

TestResultsStatus value = result.getStatus();

Parameters

This method does not take any parameters.

Return value

Type: TestResultsStatus

Use this method to retrieve one of the following enumerated values:

  • TestResultsStatus.Passed
  • TestResultsStatus.Unresolved
  • TestResultsStatus.Failed

See TestResultsStatus for details.

getSteps method

Syntax

int value = result.getSteps();

Parameters

This method does not take any parameters.

Return value

Type: int

getUrl method

Syntax

String value = result.getUrl();

Parameters

This method does not take any parameters.

Return value

Type: String

isAborted method

Syntax

boolean value = result.isAborted();

Parameters

This method does not take any parameters.

Return value

Type: boolean

Use this method to retrieve true if the test was aborted.

isDifferent method

Syntax

boolean value = result.isDifferent();

Parameters

This method does not take any parameters.

Return value

Type: boolean

isNew method

Syntax

boolean value = result.isNew();

Parameters

This method does not take any parameters.

Return value

Type: boolean

Use this method to retrieve true if this is a new test, false otherwise.