Selenium Automation Tool 

Q&A



 Read carefully and prepare the following Question and Ans for interviews 


Q 1)  What is Selenium 

Ans : Selenium is a suite of open source tool that automate web browsers across different platforms it is widely used for functional and regression testing of web applications 


Q 2) what are the different components of selenium 

Ans : The different components of selenium are Selenium IDE, Selenium RC,Selenium Webdriver, and Selenium Grid 


Q 3) what is selenium Webdriver 

Ans : Selenium Webdriver is a web automation tool that allows you to automate interactons with a web browser


Q 4)what are the advantages of using Selenium Webdriver

Ans :

 The advantage of using selenium Webdriver are :

-it supports multiple programming languages like java , rubby ,python ,etc

-it can automate inetractions with various web browser like chrome,saffari,firefox

-it supports parllel test excution using selenium  grid 

-it allows you to automate web application that use ajax,javascript,and other dynamic technologies 


Q 5) How do you handle dynamic elements usnig selenium Webdriver 

Ans : To handle dynamic elements using selenium Webdriver you can use various techniques like waits,explicit waits, implicit waits, and fluent waits. 


Q 6) What are the waits in selenium Webdriver 

Ans : Waits in selenium webdriver are used to pause the test execution for a certain amount of time until a particular conditions is met


Q 7)what is X-path in selenium Webdriver

Ans : Xpath in selenium Webdriver is a language used for a finding elements on a the next step in the test Script 


Q 8) What is difference between absolute and relative Xpath 

Ans : The main difference between absolute and relative x path is that absolute xpath starts from the root node where as relative x path starts from the current node 


Q 9) what is CSS selector in selenium Webdriver 

Ans : A CSS selector in selenium Webdriver is a pattern used to select elements on a web page based on their attributes 


Q 10) How do you handle Pop-Up window in selenium webdriver 

Ans : To handle pop up window in selenium Webdriver you can use the switchto() method to switch the focus of the Webdriver to the new window 

  

Q 11)  What are the Test NG Annotations Explain?

Ans :Annotations are order in which executed during test execution 

      There Are total 9 types of Annotations 

  1) @Beforesuite : This annotation is executed before all tests in a test suite 

  2) @ BeforeTest:This annotation is executed before all the tests in a test tag 

  3) @Beforeclass: This annotations is executed before the first test method in a test                                        class

  4) @BeforeMethod : This annotation is executed before each test method in a class 

  5) @ Test : This annotation marks a method as a test method 

  6) @AfterMethod : This annotation is executed after each test method in a class 

  7) @AfterClass : This annotation is executed after the last test method in a test class

  8) @AfterTest : This annotation is executed after all test in a test tag

  9) @AfterSuite :This annotation is executed after all tests in a test suite 




For More Information follow us