In this article, we list 10 most important Selenium interview questions that can help you in your next interview.
Question 1: What is Selenium? Tell us about its components?
Selenium is one of the most sought-after automated software testing tools that has been designed to test web applications and browsers. Due to its wide use in the tech community, it has in the recent times become one of the most accepted instruments of automated testing for professionals all over the world.
The Selenium software package consists of the following components:
• Selenium Integrated Development Environment (IDE).
• Selenium WebDriver.
• Selenium Remote Control (RC).
• Selenium Grid.
Question 2: Cite some of the limitations of the Selenium software.
Despite inherent advantages and plus points of the Selenium software, it certainly suffers from some limitations which are:
• Selenium cannot test mobile based applications.
• Reports from using the Selenium software can only be generated via third party tools such as JUnit or others like TestNG.
• Knowhow of programming language is a must to use this software.
• Selenium covers the domain of testing web applications only.
Question 3: What exactly is Selenese?
Essentially, Selenese is a kind of language using which scripts in Selenium IDE are written.
Question 4: What makes Selenium IDE an ideal software testing tool?
Well, Selenium can even be used by someone without any specialised knowledge of programming language. Apart from that, the record and playback feature of Selenium IDE ensures that one can learn the software without any hassle.
Question 5: What is the key difference between the Commands of Verify and Assert in Selenium?
The key difference between the two commands is as follows:
Verify: It verifies if the given condition is true or not. However, irrespective of the veracity of the condition, the execution of the program does not come to a halt and the test is still fully executed.
Assert: On the contrary, after checking the given condition to be true or not, the Assert command executes the program only of the condition is proper and true. In case it isn’t, further tests come to a halt.
Question 6: What is Selenium 1 and Selenium 2?
Selenium 1- It consists of Selenium Remote Control.
Selenium 2- It consists of WebDriver and elements of Selenium 1.
Question 7: What is the use of XPath?
XPath is used to find elements on a web page by using the XML path expression. It uses the HTML DOM structure to find the location of a particular element.
You may also like:
6 Questions to ask at the end of your Job Interview
10 Tips to stay focused in an Interview
Question 8: Can pop up based on Windows be handled by Selenium?
No. Since Selenium only tests web application, it cannot be used to handle Windows based pop up.
Question 9: What is the ‘same origin policy’?
The ‘same origin policy’ indicates that the content on one site cannot be accessed by a script from a different site. It has been introduced due to security reasons.
Question 10: Enlist the ways of viewing in Selenium IDE?
There are two ways to do so. You can either open it in the side bar or in the form of a pop-up window.
Apart from the above important questions, you may also be asked the following questions in your interview:
• Tell us about the testing types that Selenium can support.
• Enlist the various kinds of locators in Selenium.
• When do you think Selenium Grid should be used?
• How would you launch a browser by using WebDriver?
• Using Selenium, tell us how do you type in a textbox?
• Using LinkText, how can you click on a hyperlink?
• How can you handle web-based pop up?
• Can you tell us how to recover CSS properties of a given element?
• How can you capture a screenshot in WebDriver?
• What do you know about JUnit?
Looking for Selenium Jobs in top cities? Click at the links below:
• Selenium Jobs in Gurgaon
• Selenium Jobs in Mumbai
• Selenium Jobs in Chennai
• Selenium Jobs in Delhi
• Selenium Jobs in Pune