Creating a Web UI test with Test Genie
You can use the AI-powered Test Genie to generate test steps for a web application based on your natural language instructions.
Before you begin
- Ensured that you are a Team Space Owner, Project Owner, or Member with a Tester role to create or edit a test resource.
- Read and understood the information in Edit branch overview.
- Ensured that your project contains an application.
- Configured at least one AI provider in the Cloud Credentials page. See Adding cloud credentials of AI providers.
About this task
Test Genie accelerates test creation by translating your written instructions into a test script. The AI provider uses the application URL and the details in the application description to improve the accuracy of the generated steps.
Procedure
-
Log in to Test Hub.
The Projects page of the initial team space is displayed.
-
Click to open the project that contains the test assets.
The Overview page of the project is displayed.
-
Click .
The Test Editor page and the test navigator panel are displayed.
-
Perform one of the following options:
- Click on the Test Editor page.
- Click the Action menu icon
in the
test navigator panel to open the menu and click the
Test option. - Right-click the application in the test navigator panel and select .
Alternatively, you can create a test by clicking the Create Test
icon on the application Details page if
there is an edit branch active.The Edit branch dialog is displayed.If the Edit branch dialog is not displayed, then go to step 6. - Select an existing edit branch or create a new edit branch.
-
Perform the following steps in the Details tab of the
Create Test dialog:
- Select an application for which you want to create a test from the
Application drop-down list.
The application folder is selected as the default location for the test.
- Optional: Select a folder if there are subfolders in Location to save the test assets that you are creating.
- Enter a name for the test in Asset Name.
- Select an application for which you want to create a test from the
Application drop-down list.
-
Click Next.
The Source tab is displayed.
- Select the Create an empty test option in the Select source drop-down list.
-
Enter a set of natural language instructions for your test in the
Steps text box.
For example, for testing an e-commerce website, you can enter:
Add three sports category items to the cart
Remove one item during the checkout process
Log in with the credentials
Proceed to order -
Click Done.
An empty test is displayed in Test Editor.
-
Click the Test Genie tab.
The instructions you entered during the test creation are displayed in the Steps text box under the Test Genie tab.
- Review, modify, or add to your natural language instructions in the text box.
-
Click Generate.
The Generate Test dialog is displayed.
-
Perform the following steps in the dialog:
- Enter or modify the web address of the application under test in the Start URL field as required.
- Select an AI provider from the configured AI Provider list.
-
Click Generate.
The test generation process starts.
-
Click the Results tab and then click the Show
in progress page icon
.
The Progress page is displayed. If the page contains many jobs, you must create a filter with the rule AI Assisted Generation to filter for AI-assisted jobs. -
Select View AI interactions from the listed actions in
the Actions column of the AI-assisted job.
A new tab opens with the console output. You can view the AI interactions and session logs on the progress page by refreshing the view.
-
Switch to the test editor tab after the execution job is complete in the
Progress page.
The Reload button is displayed with the following warning: A newer version of this resource is available.
-
Click Reload.
The AI-generated test steps are displayed.
Results
You have created a Web UI test with Test Genie.
What to do next
- You can view the execution results, the model used, and the token usage details in the Test Genie tab.
- Play back the generated test. See Running a Web UI test or Running server test assets.