Home

1000+ Selenium automation Multiple Choice Question Answer [Solved]

Thursday 9th of March 2023

Sharing is caring

1. ___________ finds the item ending with the value passed in. This is the equivalent to the XPath ends-with. Is concern with?
A. ^=
B. $=
C. *=
D. &=
Answer : B
2. To delete a cookie we need to call the deleteCookie method, passing in two parameters.
A. The first parameter is the name of the cookie, and the second parameter is where it was created.
B. The first parameter is where it was created, and the second parameter is the name of cookie.
C. None of these
D. All of the above
Answer : A
3. Out of the following which is NOT a wait command.
A. waitForTitle
B. waitForTextPresent
C. waitForActive
D. waitForAlert
Answer : C
4. Selenium is compatible with
A. CSS1.0 and CSS 2.0,
B. CSS1.0, CSS 2.0, and CSS 3.0 selectors.
C. CSS 2.0, and CSS 3.0 selectors.
D. CSS1.0, CSS 2.0, CSS 3.0 and CSS 4.0 selectors.
Answer : B
5. In case of Selenium IDE, the Source view shows your script in
A. DHTML format
B. J2EE format
C. XML format
D. HTML format.
Answer : C
6. Which is a faster component between the SeleniumWeb driver and Selenium RC?
A. Selenium RC
B. Selenium Web driver
C.
D.
Answer : B
7. The Selenium can
A. access controls within the desktop
B. both web and desktop applications
C. only test web applications
D.
Answer : C
8. By Default time of WAITFOR command is :
A. 15 sec
B. 20 sec
C. 25 sec
D. 30 sec
Answer : D
9. What is TestNG?
A. TestNextGeneration
B. TestNewGenerlization
C. TestNewGeneration
D. TestNextGenerations
Answer : A
10. Selenium IDE stands for
A. Selenium Intialization Development Environment
B. Selenium Interrelated Development Environment
C. Selenium Integrated Development Environment
D. Selenium Information Development Environment
Answer : C
11. We use the dot (.) operator followed by either a * or a +. The + tells the regular expression that there will be instances between 0 and n, while the * tells the regular expression that there will be instances between 1 and n.
A. True
B. False
C.
D.
Answer : B
12. What is a test suite made of ?
A. Test packs
B. Tests
C. Test blocks
D. Test pattern
Answer : B
13. Select the method which clears all selected entries in Web driver Selenium.
A. dselectAll()
B. deselect_All()
C. dselect_All()
D. deselectAll()
Answer : D
14. The Selenium IDE is used
A. To create customized test results.
B. To deploy your tests across multiple environments using Selenium Grid
C. To test with HTMLUnit
D. To test a web application against Firefox only.
Answer : D
15. What is Selenium IDE ?
A. Windows Software
B. Firefox Plug-in
C. Java Software
D. Flash Plug-in
Answer : B
16. Select the variation which locates elements by the value of their id� attribute in Web Driver Selenium
A. By.id
B. By.idno
C. By.id_no
D. By.tag_id
Answer : A
17. Select the variation which locates elements by the value of the name� attribute in Web driver Selenium
A. By.name
B. By.nametag
C. By.tagname
D. By.nametags
Answer : A
18. Select the command which is used to compare the actual page title with an expected value.
A. verifyTitle
B. verifiedTitle
C. verifyTitles
D. verifiedTitles
Answer : A
19. Selenium variables are stored in _____________.
A. storedVars
B. storedVariables
C. VariablesStore
D. None of the above
Answer : A
20. echo(): is used
A. to display the value of a variable in the log file, which can be very valuable for debugging.
B. Display the value of a variable named answer in the log file, what would the first argument to the previous command look like.
C. Both of these
D. None of these
Answer : C
21. Select the method which selects the option at the given index.
A. selectByIndex()
B. selectIndex()
C. selectedByIndex()
D. selectByIndexes()
Answer : A
22. Which Navigate command takes you forward by one page on the browser's history in Web driver Selenium.
A. navigate.forward()
B. navigate().forward()
C. navigate()_forward()
D. navigate_forword()
Answer : B
23. Which component of Selenium can create customized test results.
A. Web driver
B. Selenium RC
C. Selenium IDE
D. Selenium Grid
Answer : A
24. Is Web Driver a component of the Selenium?
A. No
B. Yes
C.
D.
Answer : B
25. What does the assertTitle checks ?
A. Element title
B. Page title
C. Block title
D. Title of element under focus
Answer : B
26. Select the tab which gives feedback and other useful information when executing tests.
A. Information
B. Feedback
C. Reference
D. Element
Answer : C
27. Select the language which is supported by The Selenium Web Driver
A. Perl
B. Sql
C. ASP
D. Cobol
Answer : A
28. Out of the following which can only test web applications
A. QTP
B. Selenium
C.
D.
Answer : B
29. Which regular expression sequence that loosely translates to anything or nothing?
A. .* (dot star)
B. *. (star dot)
C. *?
D. *+
Answer : A
30. Which Selenium component supports All Operating System?
A. Selenium Generator
B. Selenium IDE
C. Selenium WebDriver
D.
Answer : C
31. Which is the following is true in case of waitFor command?
A. waitForAlertPresent
B. waitForTextPresent
C. waitForFramePresent
D. waitForPageToLoad
Answer : B
32. Select the language which is NOT supported by the Selenium RC.
A. ASP
B. Java
C. C#
D. PHP
Answer : A
33. Select the command which is NOT used in verifying page elements .
A. verifyElementPresent
B. verifyElementRight
C. verifyElementNotPresent
D. verifyElementPositionLeft
Answer : B
34. What does the term CSS refers to ?
A. Cascade Style Sheets
B. Cascading Style Sheets
C. Clear Style Sheets
D. Catering Style Sheets
Answer : B
35. Which method is used when you want to verify whether a certain check box, radio button, or option in a drop-down box is selected in Web driver Selenium
A. is_Selected()
B. isSelect()
C. isSelected()
D. is_Select()
Answer : C
36. Select the operating system which is NOT supported by Selenium IDE.
A. Unix
B. Linux
C. Windows
D. Solaris
Answer : A
37. Which Component is used to run multiple tests simultaneously in different browsers and platforms?
A. Selenium Grid
B. Selenium IDE
C. Selenium RC
D. Selenium Webdriver
Answer : A
38. Can Google chrome be supported by Selenium IDE?
A. Yes
B. No
C.
D.
Answer : B
39. Select the command which is used to print a string value or a variable in Selenium IDE.
A. The 'display' command
B. The 'echo' command
C. The 'print' command
D. The 'printr' command
Answer : B
40. What is called that scale for large test suites or test suites that must be run in multiple environments?
A. Selenium-Grid
B. Selenium RC
C. Selenium Web driver
D. Selenium NG
Answer : A
41. Select the syntax to locate an element using inner text.
A. css=tag:contains(inner text�)
B. css=tag:value(inner text�)
C. css=tag:attributes(inner text�)
D. css=tag:class(inner text�)
Answer : A
42. Which two commands you use to validate a button?
A. VerifyTextPresent and assertTextPresent
B. VerifyElementPresent and assertElementPresent
C. VerifyAlertPresent and assertAlertPresent
D. VerifyAlert and assertAlert
Answer : B
43. The // tells the query that
A. It needs to stop at the first element that it finds.
B. This is comment
C. The path of the file or folder
D. All of these
Answer : A
44. What is the most common way to find an element on a page?
A. ID
B. XPath
C. CSS selector
D. Name
Answer : B
45. Select the Get command which fetches the inner text of the element that you specify in Web driver Selenium.
A. getinnerText()
B. get_in_Text()
C. get_inner_Text()
D. getText()
Answer : D
46. In Selenium, Following Axis is related to:
A. Selects all the siblings after the current element
B. Selects all elements that follow the closing tab of the current elements.
C. Selects all of the siblings before the current element
D. Selects all elements that are before the current element
Answer : B
47. The term JSON refers to ______________.
A. JavaScript Object Notation
B. Java Object Notation
C. Java Object Naming
D. None of the above
Answer : A
48. Which command is used to extend the time limit of WAITFOR command?
A. Extend waitFor (time in sec)
B. waitFor (time in sec) extend
C. setTimeout (time in sec)
D. setTimeout.
Answer : D
49. Applications do not have the items needed for the tests when the tests get to commands. To get around this, we had a look at adding fro waitFor commands to test. This is related to
A. Debugging tests
B. Working with AJAX applications
C. Working with multiple windows
D. All of these
Answer : B
50. Which is a procedure?
A. Wait
B. Exit
C. WaitForProperty
D. None of these.
Answer : A

Sharing is caring