Now, QAS supports JavaScript custom steps for Test cases recorded using the Test Recorder. Follow the mentioned steps to see the examples below:
Record a Test Case in a sample website, for example, https://www.seleniumeasy.com/test/javascript-alert-box-demo.html.
On the recorded steps you would require to insert the following sample JavaScript commands based on your testing scenarios:
Execute Java Script: This command executes the JavaScript that is manually provided in the ‘Input’ field.
Execute Async Java Script: This command waits for the Java Scripts to get executed for a duration of time (milliseconds) provided by users.
Below is an example for one of the scenarios where users want to scroll down the webpage to verify the text:
In the recorded step, users need to manually add the Java Scripts for scrolling down the page as showcased in the below screenshot: