Instructions
- Create a project « Alithya GoTest familiarization »
- Create a test plan « My first test case »
- Create a functionality « Alithya GoTest text search in Google »
- Create a scenario « As a user, I want to find Alithya GoTest in a Google search »
- Create a « Setup » type test step
Add a keyword
Keyword
Arguments
URL
browser
alias
remote_url
Default arguments
Firefox
None
False
Open Browser (Selenium Library)
Chrome
Browser
{+}https://freemium.alithyagotest.com/wd/hub+
(only for the Freemium version)- Create a first test step of the "Validation" type and add the keywords
Arguments
| Step | Keyword | Arguments |
|
---|---|---|---|---|
1 | Put the mouse in the search field. Enter Alithya GoTest. | Input Text (Selenium Library) | locator: //input[@name='q'] | text: Alithya GoTest |
2 | Press Enter. | Press Key (Selenium Library) | locator: //input[@name='q'] (xpath for the input field) | key: \\13 ou ENTER (for enter key) |
3 | Check the result page. | Element Should Contain (Selenium Library) | locator: id=rcnt | expected: Alithya GoTest |
4 | Take a screenshot of the result. | Capture Page Screenshot (Selenium Library) | filename: MySearchCapture.png |
|
5 | Add a comment in the logs of the result file: My first search. | Log (Selenium Library) | message: ‘I did my first script!’ |
|
8. Create a first test step of the "TearDown" type and add the keywords
Step | Keyword | Arguments |
---|---|---|
Close the browser | Close Browser (Selenium Library) |
Once you have finished writing the script, you can run your script in the scenario by clicking on the Start button.
Go to the execution page to view the status of your script. Thanks to the "status log" functionality, you can follow the evolution of your script during its execution.
Once the script is finished, you can view the logs. The status of the execution can be red if the script or test failed, or green if everything went well.