Example
Lets take fb login as testcase,will see how to capture and export as JAVA class
- Click on the selenium IDE icon on top right corner of your browser
- Enter the url
https://facebook.com
- Click on Record button , as shown in the screenshot
- Export the usecase as java file
- Save the file in you local machine with .java extension
- Open that file it will looks like this:
- Now you can import this file into any IDE
- Assume that we are going to user eclispe,create a new package
com.example.tests
- Just copy this file and paste there
- Add the required jar files (Selenium jar + TesgNG jar)
Now you are ready to run the test.