Testing device and testing method thereof
AssigneeInstitute for Information Industry
InventorChing-Wen Lin
Life of this patent
Estimating the term…
Abstract
A testing device and a testing method thereof are provided. The testing device is connected to a terminal device running a graphical user interface (GUI). The testing device runs a testing program to start a recording procedure to execute the following steps: detecting a plurality of actions generated in response to operations on the terminal device; detecting a foreground application of the GUI; reading a plurality of pieces of object information of the foreground application; and determining the actions to record an object property operation of the foreground application and a call command. The testing device further stops the recording procedure to generate and store a script file and a reference log file. The script file includes the object property operation and the call command.
Claims14
A testing device, comprising:
- a transceiver connected to a terminal device, being configured to run a graphical user interface (GUI);
- a storage, being configured to store a testing program;
- and
- a processor electrically connected to the transceiver and the storage, being configured to run the testing program to start a recording procedure for executing the following steps of:
- detecting a plurality of actions generated in response to operations on the terminal device;
- detecting a foreground application of the GUI;
- reading a plurality of pieces of object information of the foreground application;
- determining that a first action of the actions is to execute a coordinate command, and recording an object property operation of the foreground application which corresponds to the coordinate command according to the object information;
- and
- determining that a second action of the actions is to execute a call command which switches the foreground application from a first program to a second program, and recording the call command;
- wherein the processor is further configured to stop the recording procedure to generate and store a script file and a reference log file into the storage, and the script file comprises the object property operation and the call command;
- wherein when the transceiver is disconnected from the terminal device and connected to another terminal device, the processor further runs the testing program to start a playback procedure for executing the following steps:
- analyzing the script file;
- reading the pieces of object information of the foreground application of another GUI run by the another terminal device;
- generating the coordinate command according to the pieces of object information and the object property operation;
- executing the coordinate command and the call command;
- generating a testing log file;
- and
- comparing the reference log file with the testing log file to generate a testing result.
A testing method for a testing device, the testing device comprising a transceiver, a storage and a processor, the processor being electrically connected with the transceiver and the storage, the transceiver being connected to a terminal device, the storage storing a testing program, the terminal device running a graphical user interface (GUI), and the testing method being executed by the processor and comprising the following steps of:
- (a) running the testing program to start a recording procedure;
- (b) detecting a plurality of actions generated in response to operations on the terminal device;
- (c) detecting a foreground application of the GUI;
- (d) reading a plurality of pieces of object information of the foreground application;
- (e) determining that a first action of the actions is to execute a coordinate command, and recording an object property operation of the foreground application which corresponds to the coordinate command according to the object information;
- (f) determining that a second action of the actions is to execute a call command which switches the foreground application from a first program to a second program, and recording the call command;
- (g) stopping the recording procedure to generate and store a script file and a reference log file into the storage, wherein the script file comprises the object property operation and the call command;
- wherein when the transceiver is disconnected from the terminal device and connected to another terminal device, the method further comprises the following steps of:
- executing the testing program to start a playback procedure;
- analyzing the script file;
- reading the pieces of object information of the foreground application of another GUI run by the another terminal device;
- generating the coordinate command according to the pieces of object information and the object property operation;
- executing the coordinate command and the call command;
- generating a testing log file;
- and
- comparing the reference log file with the testing log file to generate a testing result.
Dependencies are inferred from the claim text.