Test automation software may record and automatically replay user interactions with a graphical user interface (“GUI”). GUI developers may use automation software to record and replay mouse input (e.g., points and clicks) and web developers may use it to record and replay web page navigations. These tools alleviate manual testing, which is often laborious and time-consuming.
As noted above, GUI developers may use test automation to record user operations and to replay those operations automatically as many times as needed. Such tools save a significant amount of time in quality assurance and regression testing. Some test automation tools use an agent-based approach. In this approach, an agent module may be inserted into an application under test (“AUT”). The agent may record information associated with graphical objects as users interact therewith and may also replay those user interactions when needed. One advantage of an agent-based approach is the precision with which graphical data can be captured during the recording phase. An agent may capture detailed data associated with complex graphical user interfaces, such as graphical tree views and calendars. However, the agent-based approach has some disadvantages. For example, if the AUT is executing remotely, security restrictions may prevent insertion of the agent into the remote computer. Furthermore, customized agents may have to be developed for each platform. For example, specific agents may need to be developed for each version of Internet Explorer®.
In view of the foregoing, various examples disclosed herein provide a system, non-transitory computer-readable medium, and method for recording and replaying user operations. In one aspect, an appearance of a graphical object may be recorded. In a further aspect, it may be determined whether the recorded appearance is different than the current appearance of the graphical object. In another example, particular images, text, and pixel measurements of the graphical object may be recorded. Thus, the system, non-transitory computer-readable medium, and method disclosed herein may capture details of complex graphical objects based on the user interface displayed on the screen without having to insert an agent into the AUT. The techniques disclosed herein capture precise details of the displayed graphical objects commensurate with the details gathered using an agent based approach. The aspects, features and advantages of the application will be appreciated when considered with reference to the following description of examples and accompanying figures. The following description does not limit the application; rather, the scope of the application is defined by the appended claims and equivalents.
Non-transitory computer readable medium (“CRM”) 112 may store instructions that may be retrieved and executed by processor 110. As will be discussed in more detail below, the instructions may include recording module 114 and a replay module 116. Non-transitory CRM 112 may be used by or in connection with any instruction execution system that can fetch or obtain the logic from non-transitory CRM 112 and execute the instructions contained therein.
Non-transitory CRM 112 may comprise any one of many physical media such as, for example, electronic, magnetic, optical, electromagnetic, or semiconductor media. More specific examples of suitable non-transitory computer-readable media include, but are not limited to, a portable magnetic computer diskette such as floppy diskettes or hard drives, a read-only memory (“ROM”), an erasable programmable read-only memory, a portable compact disc or other storage devices that may be coupled to computer apparatus 100 directly or indirectly. Alternatively, non-transitory CRM 112 may be a random access memory (“RAM”) device or may be divided into multiple memory segments organized as dual in-line memory modules (“DIMMs”). The non-transitory CRM 112 may also include any combination of one or more of the foregoing and/or other devices as well. While only one processor and one non-transitory CRM are shown in
The instructions residing in non-transitory CRM 112 (e.g., recording module 114 and replay module 116) may comprise any set of instructions to be executed directly (such as machine code) or indirectly (such as scripts) by processor 110. In this regard, the terms “instructions,” “scripts,” and “applications” may be used interchangeably herein. The computer executable instructions may be stored in any computer language or format, such as in object code or modules of source code. Furthermore, it is understood that the instructions may be implemented in the form of hardware, software, or a combination of hardware and software and that the examples herein are merely illustrative.
In one example, recording module 114 may instruct processor 110 to record at least one user operation that changes an appearance of a graphical object to a target appearance and to record the target appearance. In another example, replay module 116 may instruct processor 110 to determine whether a current appearance of the graphical object is different from the recorded target appearance and to change the current appearance to the target appearance so as to repeat the at least one user operation.
Working examples of the system, method, and non-transitory computer-readable medium are shown in
As shown in block 202 of
Referring now to
The images, pixel measurements, and text may be recorded in a variety of ways. For example, coordinates (e.g., x and y coordinates or height and width) may be recorded via an application programming interface. For example, the pixel measurement 302 between image 304 and text 306 may be recorded by determining the x coordinates therebetween. By way of further example, the y coordinates of the expanded tree view 404 may be recorded. In another example, optical character recognition (“OCR”) may be used to record text, such as text 306 in
Referring back to
Advantageously, the above-described system, non-transitory computer readable medium, and method record details of a graphical object as a user interacts therewith and replays the user interactions by adjusting the image as did the user interactions. In this regard, fine details of the image may be recorded so that complex graphical objects may be adjusted in accordance with the recorded user operations. In turn, testing engineers can be rest assured that a high quality automated test can be carried out, even if an agent based approach is not possible.
Although the disclosure herein has been described with reference to particular examples, it is to be understood that these examples are merely illustrative of the principles of the disclosure. It is therefore to be understood that numerous modifications may be made to the examples and that other arrangements may be devised without departing from the spirit and scope of the application as defined by the appended claims. Furthermore, while particular processes are shown in a specific order in the appended drawings, such processes are not limited to any particular order unless such order is expressly set forth herein. Rather, processes may be performed in a different order or concurrently.
Filing Document | Filing Date | Country | Kind |
---|---|---|---|
PCT/CN2013/084802 | 9/30/2013 | WO | 00 |