Professional Documents
Culture Documents
SELENIUM 29april, 2024
SELENIUM 29april, 2024
presenceOfElementLocated(by));
This is an example of an implicit wait. Single Choice - Select one correct answer from the options
list.
TRUE
FALSE
FALSE
2. if method of PageFactory class PageFactory.initElements(..) is not mentioned then the expected
Exception is Single Choice - Select one correct answer from the options list.
ElementNotFoundException
ClassNotFoundException
NullPointerException
ClasspathException
ClassNotFoundException
Anonymous
What is the proper sequence of phases in Page Object Model Architecture? Single Choice - Select
one correct answer from the options list.
Option A 1.Page Object Class 2. Tests 3. Selenium WebDriver 4. Page
Option B 1. Page 2. Page Object Class 3. Selenium WebDriver 4. Tests
Option C 1. Page 2. Tests 3. Page Object Class 4 Selenium WebDriver
Option D 1. Page 2. Selenium webdriver 3. Page Object Class 4. Tests
Anonymous
What are the annotations used in TestNGSingle Choice - Select one correct answer from the
options list.
A. Pre-condition Annotations
B. Test Annotations
C. Post Condition annotations
D. All of the options
TRUE
Anonymous
_____ is a collection of factory functions for creating webdriver.Locator instances. Single Choice -
Select one correct answer from the options list. Locator By WebDriver Selector
By
Anonymous
What are the navigation methods listed below Multiple Choice - This may have multiple correct
answers. Select required answer(s) from the options list. A. refresh() B. back() C. forward() D. to()
switchTo()
Anonymous
Which of the following parameters is not required to initialize Fluent wait Single Choice - Select
one correct answer from the options list.
A. The maximum amount of time to wait for a condition.
B. The frequency to check the success or failure of a specified condition
C. Exception classes to ignore while waiting.
D. Expected condition to wait.
FALSE
Anonymous
What are the different navigation methods of WebDriver Multiple Choice - This may have
multiple correct answers. Select required answer(s) from the options list. A. back() B. goto() C.
refresh() D. forward() E. moveto()
A. back() C. refresh() D. forward()
Anonymous
If our program contains two feature files, with one step definition file in which there is a @Before
Hook, will this hook execute before both feature files? Single Choice - Select one correct answer
from the options list. TRUE FALSE
FALSE
Anonymous
What is the use of Firebug in Selenium? Single Choice - Select one correct answer from the
options list.
A. Programming
B. Inspecting Elements
C. Parallel Testing
D. Cross Browser Testing
B. Inspecting Elements
Anonymous
In webdriver, which of the following is a valid select statement that selects a value from a drop
down element? Single Choice - Select one correct answer from the options list. selectByIndex()
selectByVisibleText() selectByValue() all above none of above
all above
Anonymous
Which of the following statements is correctly defining the Time-out test in TestNG Single Choice
- Select one correct answer from the options list.
A. It's the time duration to wait for a test to finish its execution
B. It's the time duration to wait for a test suite to finish its execution.
C. It's the time duration to wait for a test group to finish its execution.
D. None
A. It's the time duration to wait for a test to finish its execution
Anonymous
Select method used to get location of the top left-hand corner of the element Single Choice -
Select one correct answer from the options list.
A. Point getLocation()
B. Point getSize()
C. Point getPoint()
D. Point getRect()
A. Point getLocation()
Anonymous
Which of the following options are valid ways to access an element by id? Single Choice - Select
one correct answer from the options list. A. driver.findElement(By.xpath("//*[id='plans']")) B.
driver.findElement(By.xpath("//*[@id='plans']"))
B. driver.findElement(By.xpath("//*[@id='plans']"))
Anonymous
What is the method called to perform sequence of mouse actions?? Single Choice - Select one
correct answer from the options list.
execute()
build()
perform()
run()
perform()
Anonymous
Select the propertyName which is not a valid CSS Property passed for a method java.lang.String
getCssValue(java.lang.Strin g propertyName) Single Choice - Select one correct answer from the
options list. A. background B. font C. padding D. xpath
D. xpath
Anonymous
The rule can be used to test both exception type and message. Single Choice - Select one correct
answer from the options list.
A. Expected B. ExpectedException C. CatchException D. Catch
A. Expected
Anonymous
What is the method used to check the WebElement is present Single Choice - Select one correct
answer from the options list.
.isDisplayed()
.isVisible()
.isClear()
.isPresent()
.isPresent()
Anonymous
How do you launch a web browser using Selenium WebDriver in Java? Single Choice - Select one
correct answer from the options list.
A. driver.open("chrome");
B. OpenBrowser("chrome");
C. WebDriver driver = new ChromeDriver();
D. launchChrome();
C. WebDriver driver = new ChromeDriver();
Anonymous
How can you locate an element by its ID using Selenium WebDriver? Single Choice - Select one
correct answer from the options list.
A. driver.findElement(By.Name("elementName"))
B. driver.findElement(By.LinkText("elementLink"))
C. driver.findElement(By.XPath("elementXPath"))
D. driver.findElement(By.ID("elementID"))
Anonymous
What is the interface available in Selenium Single Choice - Select one correct answer from the
options list. A. Select B. WebDriverWait C. WebDriver D. Selenium
C. WebDriver
Anonymous
Which of the following statements is correctly defining the Time-out test in TestNG Single Choice
- Select one correct answer from the options list.
A. It's the time duration to wait for a test to finish its execution
B. It's the time duration to wait for a test suite to finish its execution.
C. It's the time duration to wait for a test group to finish its execution.
D. None
A. It's the time duration to wait for a test to finish its execution
Anonymous
Select the correct code to set the remote WebDriver to Firefox browser with version 20 and
Windows platform. Single Choice - Select one correct answer from the options list.
A. Desired Capabilities capabilities=new Desired Capabilities(); capabilities.setPlatform
(Platform.WINDOWS); capabilities.setBrowser("firefox"); capabilities.setVersion("20");
TRUE
Anonymous
Single Choice - Select one correct answer from the options list. Selenium IDE supports Browser
only to create and execute Test Cases. A. Google Chrome B. Internet Explorer C. Mozilla Firefox D.
Opera
C. Mozilla Firefox
Anonymous
What is the difference between findElement() and findElements() in Selenium? Single Choice -
Select one correct answer from the options list.
A. Both methods return a single element
B. findElements() returns a single element, findElement() returns a list
C. Neither method is used in Selenium
D. ) findElement() returns a single element, findElements() returns a list
ChatGPT
ChatGPT
D. findElement() returns a single element, findElements() returns a list
Anonymous
What is the purpose of the "findElement" method in Selenium? Single Choice - Select one correct
answer from the options list. A. To maximize the browser window B. To locate and interact with a
single web element C. To close the browser D. To take screenshots
ChatGPT
ChatGPT
Anonymous
What is the correct way to exclude a test in TestNG Single Choice - Select one correct answer from
the options list. A. Using @Test(enabled = false) annotation B. None C. Using @Test(exclude = true)
annotation D. Using @Test(include = false) annotation
ChatGPT
ChatGPT
A. Using @Test(enabled = false) annotation
Anonymous
Action is the class used to perform Keyword and mouse Actions in Selenium Webdriver. Single
Choice - Select one correct answer from the options list. TRUE FALSE
ChatGPT
ChatGPT
TRUE
Anonymous
Which of the following exceptions is not an ideal candidate to ignore via FluentWait? Single
Choice - Select one correct answer from the options list. A. TimeoutException B.
NoAlertPresentException C. NoSuchElementException E. Element NotVisibleException
ChatGPT
ChatGPT
B. NoAlertPresentException
Anonymous
Select the propertyName which is not a valid CSS Property passed for a method java.lang.String
getCssValue(java.lang.Strin g propertyName) Single Choice - Select one correct answer from the
options list. A. background B. font C. padding D. xpath
ChatGPT
ChatGPT
D. xpath
Anonymous
Which of the following statements is correctly defining the Time-out test in TestNG Single Choice
- Select one correct answer from the options list. A. It's the time duration to wait for a test to
finish its execution B. It's the time duration to wait for a test suite to finish its execution. C. It's the
time duration to wait for a test group to finish its execution. D. None
ChatGPT
ChatGPT
A. It's the time duration to wait for a test to finish its execution
Anonymous
Select method useful to get the width and height of the rendered element Single Choice - Select
one correct answer from the options list. A. Location getValue() B. Point getPoint() C. Dimension
getSize() D. Rect getLocation()
ChatGPT
ChatGPT
C. Dimension getSize()
Anonymous
_______ doesn't support Test design (Creating test Cases) Single Choice - Select one correct
answer from the options list. Selenium IDE Selenium RC Selenium WebDriver Selenium Grid
ChatGPT
ChatGPT
Selenium Grid
Anonymous
______ doesn't support Test design (Creating test Cases) Single Choice - Select one correct answer
from the options list. A. Selenium IDE B. Selenium RC C. Selenium WebDriver D. Selenium Grid
ChatGPT
ChatGPT
A. Selenium IDE