Selenium Test Cases
A Selenium Test Case is a set of conditions or actions which are performed on the software application in order to verify the expected functionality. With Selenium Test Cases, a tester will determine whether an application or one of its features is working as it was originally established.
The Test Case can be collated into Test Suites. To learn more about Test Suites, read Selenium Test Suites article.
Creating Selenium Test Cases
To create a new Selenium Test Case, get into Copado Selenium Testing application and follow these steps:
- Click on the Selenium Test Cases tab.
- Press the "New" button.
- Enter a name for the test case. It is a good practice to add a prefix to test case's name depending on the type of testing. For example, if the test case you are creating is part of the Regression Tests pack, add “RT_” prefix to its name to better identify it and make searches easier. You can use same criteria for other types of tests (AC for acceptance tests, UT for unit tests, etc.).
- Click Save.
- Open the Copado Recorder and start reproducing the steps of the case. Do not forget to check on "Recording" button.
- Once you are finished, save the recording. You can continue editing or even remove all steps with "Clear test case" button. To learn more about Copado Recorder, get into Useful Tips & Commands when recording Test Cases.
A test case is often referred to as a test script when written. Within Copado a Selenium Test Case is typically created and edited with the Copado Selenium IDE, but experienced users can create and edit Selenium Test Cases manually. When a test case is recorded using the Copado Recorder, interactions on Salesforce or your website are captured automatically and assertions can be made based on the expected output.
Copado Recorder pre-requisites
To work with Copado Recorder you will need to take into account the next points:
- First of all, follow the Getting Started instructions. You will have to bind the Copado Selenium IDE to the Org and configure your Selenium Settings.
- When a Selenium Test Case is created, the recording will use the default values generated with every step.
- Use the "+ new dataset" button to override the recorded values and reuse the same script with different data. Then, created datasets will be available when creating a Selenium Test Suite. To see how to do it, visit Selenium Test Suites.
- Copado allows you to track versions of Selenium Test Cases. See Versioning Selenium Test Cases to learn more.