close method

Class: EyesPlatform: Selenium 3Language: Python SDK:

Call this method at the end of the test. This terminates the sequence of checkpoints, and then waits synchronously for the test results and returns them.

If your tests can run concurrently and you don't need to wait for the results before starting the next test, then it is highly recommended that you call the method Eyes.close_async instead of this method. the call to close_async ends the test without waiting for the results and the next test can start immediately, greatly reducing overall test time. When you use close_async, you obtain the results by calling get_all_test_results after all the tests have run.

Syntax


result = eyes.close(raise_ex)

result = eyes.close()

Parameters

raise_ex
Type:bool [Optional : default = True ]
If this parameter has a value of True, then if there are new, missing, or mismatched steps, an exception will be thrown. If the parameter is set to False, then an exception will not be thrown for the above cases. If the parameter is not passed, then it is as if a True value was passed.

Return value

Type: <a class ='link' href='/Content/api/eyes-sdk/index-gen/class-testresults-selenium-python_sdk4.htm'>TestResults</a>

The result of the test can be obtained from the object returned. See TestResults class for a list of what information can be obtained from this object. See TestResults class for a list of what information can be obtained from this object.

Remarks

If this test is run on the Ultrafast Grid, and there is more than one target browser or device configured, then this method only returns the first result to be available. You can obtain the results for all the test targets by calling VisualGridRunner.get_all_test_results after all the tests have completed.