Tik-76.115 Individual Project: Guinea Pig
$Id: abx_python_interface.html,v 1.1 1996/04/22 08:15:30 kepa Exp $

Testee UI - A/B/X Test Python interface

This document describes the Python interface of A/B/X Test. It is used to interface the A/B/X Test Logic module to A/B/X Test Testee UI. See the A/B/X Test User Manual for a general overview. Here's a snapshot of the A/B/X Test GUI:

[Image]

Using abx_gui class

You can use the gui_client class init('abx') method call to create an abx_gui class GUI instance. See Testee UI Python interfaces for more information.

When you have made an abx_gui class instance abx, you can use the arm() method to put the GUI in idle state and reset all variables.

   abx.arm()
With the enable() method call you enable the testee to give his/her answer. to give an answer.
   abx.enable()
You can receive the testee responses with the get_event() method. It returns a tuple that contains three values: a string, a list and a float. The first string is the type of the testee event. It can be either a BUTTON or an ANSWER. The gui will send any number of BUTTON events followed by a single ANSWER event.

The list contains the event parameters. In a button event this list will contain one string, which is the button the testee pressed ('A', 'B', 'X' or 'STOP'). In the case of an answer event, the list will contain one string which is 'A' or 'B' depending on the user answer.

The float returned is the system clock time at the time of the answer was given (as returned by the python time.time() method).

   type, params, timestamp = abx.get_event()
When the test is over, the GUI is closed with the close() method. You should not access the object after calling this method.
   abx.close()
   abx = None


. Testee UI Python interfaces · Testee UI Architecture · Testee UI Index · Document index · Guinea Pig ·