Wayground logo

Free Printable Worksheets

Font size

S
M
L
XL
Worksheets

selenium mock test - 7/5/19 - 18:00

Total questions: 50

Worksheet time: 25mins

Name
Class
Date
1.

_____________ is a valid select statement to selects a value from a drop down element, in webdriver.

a)

selectByValue()

b)

selectByVisibleText()

c)

selectByIndex()

d)

All of these

2.

What is the benefit of Selenium Webdriver as compared to Selenium RC

a)

WebDriver is a compact object-oriented API

b)

WebDriver drives the browser much more effectively

c)

WebDriver overcomes the limitation of single-host origin policy

d)

All of these

3.

Which Selenium driver can be used for testing for Windows 10?

a)

Edge Driver

b)

Internet Explorer Driver

c)

Both Edge Driver and Internet Explorer Driver

d)

Depends upon AUT

4.

Which of the following web element does, submit function is applicable, in Selenium WebDriver?

a)

radio button

b)

drop down

c)

text box

d)

All of these

5.

Which exception is thrown when an error has occurred on the server side?

a)

ErrorInResponseException

b)

ErrorException

c)

ErrorInException

d)

ErrorResponseException

6.

Which domain does web application carter to?

a)

B2C or e-commerce

b)

B2B or trading websites

c)

Organizational internal needs

d)

All of these

7.

The number of pop-ups Selenium can manage, is

a)

None of these

b)

2.0

c)

1.0

d)

0.0

8.

Which amongst the following statement holds true about Data Driven Framework?

a)

Only supports Modular framework

b)

Only supports Keyword Driven Framework

c)

Yes, Selenium supports Data Driven Framework

d)

No, Selenium supports Data Driven Framework

9.

In WebDriver Selenium, which GET command is used to fetch the inner text of the element being specified?

a)

getinnerText()

b)

get_in_Text()

c)

get_inner_Text()

d)

getText()

10.

Which of the following, will get all the cookies for the current domain?

a)

Cookie method

b)

Cookies method

c)

getCookie method

d)

getCookies method

11.

Which CSS version is Selenium compatible with?

a)

CSS 1.0, CSS 2.0 and CSS 3.0 selectors

b)

CSS 1.0 and CSS 2.0

c)

CSS 2.0 and CSS 3.0 selectors

d)

CSS 1.0, CSS 2.0, CSS 3.0 and CSS 4.0 selectors

12.

What is the file extension of Firefox plugins supported earlier by Firefox, on Windows?

a)

exe

b)

com

c)

dll

d)

None of these

13.

ANT is a _____

a)

Build Tool

b)

Build Tools only for .NET

c)

Build tool only for Java

d)

A language

14.

What is needed for development and testing for Python project with Selenium?

a)

pip

b)

setuptools

c)

python driver

d)

All of these

15.

Which button on the toolbar starts the test?

a)

Initiate

b)

Go

c)

Run

d)

Start

16.

*** DROPPED EMAIL ***

Which of the following options hold true according to the HTML code snippet?

12

34

driver.findElement(By.xpath("//table/tr[1]/td")).getText();

a)

WebDriver statement is incorrect.

b)

The above statement returns 1

c)

The xpath query is incorrect

d)

The above statement returns 3

17.

Which of the following command pauses execution for adding an element in the page

a)

assertElementPresent

b)

pause

c)

waitForElementPresent

d)

None of these

18.

Which Jenkins job type, is usually selected for integrating with Selenium?

a)

Maven project

b)

Free style project

c)

External Job

d)

None of these

19.

What easily identifies an element

a)

Attribute

b)

CSS Selector

c)

DOM

d)

ID

20.

What is Maven?

a)

Tool for building Java projects

b)

Build automation tool

c)

software tool for project management

d)

All of these

21.

Which of the following is usually used to find an specific element on a page?

a)

CSS Selector

b)

XPath

c)

ID

d)

Name

22.

What is the data type of parameter of getCookies method

a)

list

b)

char

c)

string

d)

None of these

23.

Which label specify a globbing pattern pattern parameter for a Selenese command?

a)

pattern

b)

glob

c)

regex

d)

None

24.

Which of the following Jenkins trigger format, will schedule your build every minute?

a)

* * * * *

b)

0 * * * *

c)

* * * * 0

d)

* * * * *

25.

How many values separated by comma, does movementsString argument in dragAndDrop selenium action, take

a)

1

b)

2

c)

3

d)

4

26.

Which amongst the following is not considered as an advantage of Selenium IDE?

a)

Intelligent field selection will use IDs, names, or XPath as needed.

b)

None of these

c)

Support of Selenium user-extension .jr file

d)

Auto complete for all common Selenium commands

27.

How many parameters are accepted by an wait function of a custom action, used to extend Selenium

a)

5 parameters

b)

4 parameters

c)

3 parameters

d)

2 parameters

28.

What is the application of the Selenium

a)

Provides professional customer support

b)

Test Reports are generated automatically

c)

Comes with a built-in object repository

d)

Cannot access elements outside of the web application under test

29.

Which CSS selector will locate a element with ID ending with the the text userName?

a)

input[id^='_userName']

b)

input[id$='_userName']

c)

input[id*='_userName']

d)

None of these

30.

Which type of Selenium calls are wrapped in wrapper method?

a)

Logging functions

b)

JSON Data exchange

c)

I/O calls

d)

frequently used selenium calls

31.

__________ is referred as the scale for large test suites or the test suites that must be run in multiple environments.

a)

Selenium-Grid

b)

Selenium RC

c)

Selenium WebDriver

d)

Selenium NG

32.

Select a value for browserName parameter in Selenium Grid configuration, which is invalid

a)

internet explorer

b)

opera

c)

chrome

d)

None of these

33.

Which CSS selector will locate an element with ID starting with the text ctrl?

a)

input[id^='ctrl']

b)

input[id$='ctrl']

c)

input[id*='ctrl']

d)

None of these

34.

Which Selenium RC component receives Selenium commands from test program

a)

Selenium Server

b)

AUT

c)

Client Libraries

d)

HTTP Proxy

35.

What is the main advantage of linear framework of software testing?

a)

Automation expertise is not necessary, as we are just using 'Record and Playback' feature.

b)

Test scripts can be easily written and it will consume minimal time to write these scripts.

c)

Understanding the flow is comparatively easy as the scripts are written in a linear manner.

d)

All of these

36.

Which of the following does not requires running Selenium-Server?

a)

using Selenium-Grid

b)

run tests to a remote machine

c)

using Selenium-Grid and run tests to a remote machine

d)

browser and tests will all run on the same machine

37.

The echo command gives it's output to

a)

Browser Window

b)

Printer

c)

Log File

d)

Screen

38.

Which parallel attribute option, is suitable to group all classes that are not thread safe, while parallelizing test runs in Selenium with TestNG?

a)

methods

b)

tests

c)

classes

d)

None of these

39.

Which exception is thrown when an alert is not yet on the screen?

a)

AlertPresentException

b)

NoAlertException

c)

NoAlertPresentException

d)

None of these

40.

What routes the selenese requests from the Test in Selenium grid?

a)

Selenium hub

b)

Selenium Remote Control

c)

Selenium Server

d)

Depends upon AUT

41.

Which operating system is supported by AutoIT

a)

Linux

b)

Mac OS X

c)

Windows

d)

All of these

42.

Which year did Selenium was launched?

a)

Year 2002

b)

Year 2003

c)

Year 2004

d)

Year 2005

43.

What is Selenium RC?

a)

It provides an API and library for each of its supports languages like Java, Ruby, Python, Perl and C#

b)

It allows us to use a programming language for maximum flexibility and extensibility in developing test logic

c)

Selenium RC starts up browsers(one at a time) and then runs commands we pass along from our tests

d)

All of these

44.

Which method is used to access cookies?

a)

getCookie

b)

Cookie

c)

fetchCookie

d)

Fetch

45.

Which of the following commands is used to pause execution till the time specified element appears?

a)

waitForElementPresent

b)

waitForPagePresent

c)

waitForTablePresent

d)

waitForFieldPresent

46.

Which of the following makes use of XPath?

a)

XML Documents

b)

MS-Word Documents

c)

MS-Excel Documents

d)

MS-Powerpoint Documents

47.

The component of Selenium that can create customized test results is _________

a)

WebDriver

b)

Selenium RC

c)

Selenium IDE

d)

Selenium Grid

48.

What kind of application is the Selenium IDE?

a)

Firefox add-on

b)

Web application

c)

Windows application

d)

None of these

49.

Which programming language did the earliest version of Selenium was developed, in?

a)

PHP

b)

Python

c)

JavaScript

d)

C++

50.

Which CSS selector will locate a element with ID containing the text userName?

a)

input[id^='_userName']

b)

input[id$='_userName']

c)

input[id*='_userName']

d)

None of these