Adding Python GUI Tests

How to add Python GUI tests to check graphical output.

Python GUI tests allow you to evaluate graphics produced using Python.

The options for this test are described below.

Description

The test description shown to the user.

Solution Code

The Python code used to generate the solution image when the test is run. You can generate a sample of what this will look like by clicking the Run button.

Solution Output

The sample output generated with your solution code (click Run to generate).

Shared

If the results from the test should be shared with the user.

Height

The height of the canvas area used to generate the image. Make as small as possible for higher test accuracy.

Width

The width of the canvas area used to generate the image. Make as small as possible for higher test accuracy.

Tolerance %

The tolerance threshold to consider the test to have passed. A tolerance value of 0 means the images must match exactly. The percent difference between the images will be affected by the size of the image canvas.