PractiTest supports the execution of both Manual and Automated Tests, allowing you to run tests from any commercial tool (e.g. Selenium, Watir, QTP, Silk, etc.) or home-grown tools.
There are two different ways of working with automation and PractiTest:
- PractiTest’s API – you initialize your automated tests (via cron, scheduler, scripts, etc.), and at the end of the test you call PractiTest’s API functions to update your results. Click here find out more about how to update PractiTest via our API.
- PractiTest’s xBot – PractiTest helps you to schedule and run the tests via the xBot client. More information about how it works below.
How does PractiTest’s Test Automation work?
- You define your automated tests in PractiTest Test Library. Each automated test has it’s client_id (optional), the address of the the script to run, and the location of the result file(s) to upload upon the completion of the run.
- Download and install the PractiTest xBot for Automation on each of the machine(s) that will run the automation script(s). The xBot for Automation is a Java client that works (like Practitest) on all Windows, Mac and Linux machines.
- In order to run your tests, you create Test Sets as you would normally do with any test in PractiTest. You should then define the Planned Execution Time for each Test Set or if you want to for each Test Instance (based on your methodology).
- The xBot is design to silently contact the PractiTest server once a minute, asking for the next available script to run. As soon as there is a test to be run, the PractiTest server sends it to the xBot ogether with the path to the script and to the relevant result files. The Xbot will run the Test on the machine and upload the results back to the PractiTest server.
Automated Tests Parameters
These settings are available only for projects participating in the private beta, in order to join this program contact us. Later on this feature will be available as part of our Enterprise License.
- A manual test becomes an automated test by checking the ‘Is Automated’ checkbox.
- The field Client ID refers to the unique id for the xBot client machine that should run the test (as defined in the configuration of the xBot bellow). If the test can run on ANY CLIENT this field should be left empty.
- The Script Path is the path from the xBot client machine to the automated test itself (for example a path to a script written in Selenium). Make sure all machines can access this address.
- The Results Path is the path from the xBot client machine to the automated test result file(s). It can be the path to a single file or to a directory. At the end of the script execution the XBot will upload files from this path to the PractiTest server.
- Number of results files to upload – this tells the xBot how many files to upload from the Results Path. If the number is 3, the xBot will upload the latest 3 files to be updated or created in this directory. If the Results Path is a file, the number here is irrelevant.
- To run Automated Test Scripts you should create a Test Set and add the relevant test instances for the automated test (more on TestSets and Runs)
- The test(s) will be executed based on the Planned Execution time as defined on either the Test Set or the Test Instance.
Defining the Test results for your scripts
The xBot will send report to the PractiTest server the results of your automated tests based on the following convention:
- A Passed Test should result with 0 (zero).
- A Failed Test is everything but 0.
In addition the xBot will send the results file(s) to PractiTest server
- Each of the uploaded files will be saved as an attachment of the automation run.
- The xBot will upload the latest defined number of files in the specified directory, or a specific file.
XBot Configuration
- Download and run the xBot client from here
- Right-click on the PractiTest icon on the computer tray, and click Preferences
- Set the Client Id, and the Account’s Key and Secret Key. If you don’t know your account’s keys, contact your account administrator.
- Press update, and you can look at the log → it tells each time the xBot is communicating with PractiTest server.