What good is a line-by-line code walk-through, if you can’t execute and see the output? So without any more fuss, let’s run our code!!
Eclipse gives us the power to do this very same task in 3 ways,
- Method 1: Click on the ‘Run’ shortcut icon in Eclipse.
- Method 2: Right click on the class file, Run As -> Java Application.
- Method 3: Use the combination, CTRL+F11.
Sprinkling in some visual relief:
Executing our test will open a new Firefox browser window and perform the test steps as per the code. The output is displayed in the console as shown in the above screenshot.
Time for the first BrainBell of WebDriver series: Recall! Do you know that in the process of remembering things, we even add new thoughts to it? Recalling is an on-the-fly reconstruction of elements scattered in our brain – call it, creative re-imagination. The more you recall, the better you remember!
So recall how we came up with the code for our fist scenario that we just executed and you are all equipped to try some simple scenarios of your own. Give me a shout in the comments section if you encounter any bumps in your journey.
See you again in another post! Have a nice day!