You are on page 1of 30

1. What tests can selenium do?

Functional Regression Both a and b None of the above


2. Selenium can be used for Web based and window based testing

TRUE FALSE
3. Following is not the type of Selenium.

Selenium Grid Selenium Core Tellerium SIDE


4. Selenium IDE is the add on only for the following browser.

Chrome Firefox Safari Internet Explorer


5. Selenium can be deployed on the following Operating Systems

windows, linux Solaris,OS X Both a and b None of the above


6. What is selenese?

Selenium commands Selenium keywords Selenium Class None of the above


7. How do you execute the tests recorded in Selenium IDE in other browsers?

Selenium Remote All of the


Selenium 3 Selenium Core Control above
8. Is it possible to start the Remote engine more than once in an instance?

Yes No
9. Which of the following we use to check the properties of a web page?

Asset Command Verify Command Both a and b None of the above


10. Each testcase of Selenium RC will invokes the browser and closes after playing back.Justify?

TRUE FALSE
11. We can set multiple breakpoints in Selenium IDE.Justify

Yes No
12. The following elements in your CLASSPATH to run your Junit tests?

JAR files of class


Location of libraries that are
Location of your JUnit testsuites to be required by classes
The JUnit JAR file. test classes. tested. to be tested.
13. The following is not the Junit annotation?

The @DataProvider the @Test The @AfterClass the @BeforeClass


14. How does Jnuit parameterize a class?

Using the Using the


Using The @AfterClass Using the @Data @RunWith @Parameterize
Annotation Annotation Annotation annotation
15. How do you run the Junit tests from the command line?
java java JUnitCore java
org.junit.runner.<test Run Junit <test <test class org.junit.runner.JUnitCor
class name> name> name> e <test class name>
16. The syntax to compile a Junit Test Class is?

javac -cp junit- javac -np junit-


javac -cp junit-4.4.jar javac junit-4.4.jar 4.4 4.4.jar
HelloTest.java HelloTest.java HelloTest.java HelloTest.java
17. What are the front end web driver languages?

Javascript and
Java and C# Ruby and Python Java C# and Ruby
18. The command to access the alert is

Alert alert = alert = Alert alert = alert =


driver.switchTo().alert(); driver.switchTo().alert(); driver.alert(); driver.alert();
19. driver= new FirefoxDriver() is the command used to create a new instance of the browser in
Web Driver.Justify

TRUE FALSE
20. Web Driver allows the implementation of listeners.Justify?

TRUE FALSE
21. TestNg will execute the tests in

The order they are The order in


The order they are found found in the @Test which they are
in the Xml file annotation written None of the above
22. Advantage of Page Object

Reusability Modularity Portability All of the above


23. The ---------- has a plug-in system that allows you to easy extension and customization.

Selenium IDE Selenium WebDriver Selenium Grid Selenium Core


24. What is the Selenium IDE plug in to run the Selenium Test Suite?

Flex Pilot Whit Code Plexer Test Runner Test Suite Runner
25. storeFooPresent(variable) does

stores the text of the Stores the text of stores the text
pop-up in a variable and pop-up into some of the pop-up in
returns true or false default variable a variable Both a and b
26. Does selenium IDE support looping?

TRUE FALSE
27. Selenium will show some security notifications when handling

Proxy Settings HTTP Sites Both a and b None of the above


28. What is the default file type for capturing screenshots?
.jpeg .jpg .img .png
29. The attribute which can be used only at the class level is

threadPoolSize Priority successPercentage singleThreaded


30. The ---------- should be used to run more than one instance of IEDRiver at a time

Virtual Machines Remote Web Driver Both a and b None of the above
31. IS Selenium Web Driver ThreadSafe?

Yes No
32. A ------ is a mechanism that stores all the locators for a test suite in one place for easy
modification

Repository Object Storer UI map None of the above


33. The ------------- cab be used in instantiating their page objects

Factory PageFactory Decorators DecoratorFactory


34. The ------------ is pure DHTML/JavaScript

Selenium Web Driver Selenium Grid Selenium Core None of the above
35. The time to wait for a particular element is in terms of

Seconds MilliSeconds MicroSeconds PicoSeconds


36. Following is not the step to run automation using Selenium

Modify the
scripts
according to Viewing the
Record the scripts using thetesting results in the
Selenium IDE Run the test needs. format specified.
37. What is Selenium's recording language?

Hyper text markup


Java C# Ruby language
38. Selenium will record any operation that you do on your computer apart from the events on the
Firefox browser window.

TRUE FALSE
39. Selenium automates

Browsers Navigators urls None of the above


40. Select the disadvantage of Selenium from the following?

Does not The software with


support file which it developed
It is simple, easy to install Run multiple tests at upload from is browser based
and easy to work. a time. local machine. and agile adpted.
41. Selenium less powerful in creation of scripts because

Many actions are not All the actions IDE doesnot record and All of the above
performed are we have to do
recorded by IDE and have recorded by complete scripting
to be manually entered. IDE. manually.
42. The following is used to run the exported tests in any browser and any platform?

Selenium Remote
Selenium 2 Selenium Core Control None of the above
43. Which of the following uses native JavaScript calls.

Selenium Web
Selenium Core Selenium Grid SIDE Driver
44. Selenium Core TestRunner is used to

open the browser Not used to run


Open up the browser to and execute the test any kind of tests
test runner script. in Selenium IDE Both a and b
45. What is the main language that drives Selenium IDE

Java Python Ruby VBScripting


46. Assert and Verify are used for

Validating the elements


that are available on the Validating the
application elements only on the It is not used for
under test current page. validating. None of the above
47. The following is used to add the assert or verify to the test

Selenium IDE Context Menu Slider bar Base Url tab


48. How do you start Selenium RC?

java -jar selenium-


server-standalone-
Start Selenium RC Server <version-number>.jar Start RC None of the above
49. How do you identify an object in Selenium?

HTML code DOM with firebug CSS Firepath


50. Which are the annotations generated with JUnit 4 tests in Selenium IDE?

@Before public void @Test public void @After public


method() method() void method() All of the above
51. How to start selenium rc server with user extensions?

java -jar
selenium-
server.jar -
java -jar selenium- java -jar selenium- userExtensions Start
server.jar user- server.jar - user- SeleniumServer
extensions.js userExtensions.js extensions.js User-extensions.js
52. How to run Selenium IDE test suite with user extensions using Selenium Remote Control?
java -jar
selenium-
server.jar -
userExtensions java -jar selenium-
java -jar selenium- user- server.jar -
server.jar user- extensions.js - userExtensions
java -jar selenium- extensions.js - htmlSuite user-extensions.js
server.jar - htmlSuite "*<browser>" -htmlSuite
userExtensions user- "*<browser>" "<base URL>" "*<browser>"
extensions.js -htmlSuite "<base URL>" "<Selenium test "<base URL>"
"*<browser>" "<Selenium test suite suite file>" "<Selenium test
"<Selenium test suite file>" "<results log "<results log suite file>"
file>" "<results log file>" - file>" -timeout file>" -timeout "<results log file>"
timeout <millise> <millise> <millise> -timeout <millise>
53. If the default port of selenium is busy then which port you use?

Need to define
our own port as
Need to create our java -jar
We need to stop till the own port from where SeleniumServer.ja
port gets free the script runs r -port 1111 None of the above
54. When to use proxy injection mode?

Used when the


When we need to script is recorded
activate the proxy for in one browser
When we run the script the browser In which To inject the and we need to
in the browser where we the application is proxy for the run in some other
recorded the test open browser browser.
55. Silver light application testing is possible in following type of selenium?

Selenium Remote
Selenium Web Driver Control Selenium Grid Selenium IDE
56. How do you edit the recorded command in IDE?

By selecting the
command and choosing
the desired value from Edit->Recording No optionis
drop-down. Mode available Both a and b
57. What are the three major components of Selenium IDE?

Command, Command, Order, Target,


Command, Target, Value Destination, Value Target, Input Value
58. Which is the command used for displaying the values of a variable into the output console or
log?

Echo $<constant Echo $<variable


Echo <constant string> string> name> None of the above
59. The client libraries of Selenium RC instructs Selenium Server on
How to test the
AUT by passing How to test the
How to test the AUT it your test test scripts
by using selenium scripts Selenium Selenium
How to test the AUT commands commands commands
60. Which of the following translates its selenium commands into client drivers API's finctions?

Selenium Remote
Selenium2 Selenium Core SIDE Control
61. The following test engine is used for Java programming language?

Junit TestNG Nunit Both a and b


62. How many types of reports can be generated for java in Selenium?

No Count and are still


emerging 4 2 Not there
63. Name the Selenium API method that is used to Java script from Selenium RC?

Execute .JS
<selenium-
Exceute Js API getEval API server.jar> None of the above
64. Multi mode is the default behaviour for?

Selenium Web Driver Selenium Core Selenium Grid Selenium 1.0


65. Select the command that can be used to record valuable debugging information reported by the

selenium server to a text file.

the -include log the -log to text


command the -log command file command None of the above
66. Which of the following is more useful to the end user than the regular Selenium Server logs?

the -
the -browserSideLog the -browserLog browsersidelogs
command command command All of the above
67. The main restriction of Selenium is

Same Origin
Same Origin Policy Policy for Security
Same Origin Policy for all browsers security issues Restrictions
68. The method that was used by selenium initially to avoid the Same Origin Policy was

Enable Origin
Enable Same Origin Policy for all
Policy Proxy Injection browsers None of the above
69. Mechanism that stores all the locators for a test suite in one place for easy modification when
identifiers or paths to UI elemets changes in the AUT is?
Suite UI
elements
Locator Suite Details Ui Map locators None of the above
70. Rapid prototyping tool is

Selenium Rc Selenium Web Driver SIDE Selenium Core


71. Which of the following is not the pane of Selenium IDE?

Log Ui-Element Reference TestCase Name


72. The two ways of editing a command or comment is Selenium IDE are?

Command,
Table and Source Table and Target Target, Input None of the above
73. Toggle Breakpoint is used to

can set a breakpoint


in the test case to
cause it to stop on a
set a breakpoint in the particular command
test case to cause it to and
stop on a particular exceute from the
command. scratch Both a and b Only 1
74. The three flavours of Selenium Commands are

Actions,
Assertions, Actions Accessors and
Command, Target, Value and Ino\puts Assertions All of the above
75. The three modes in which we can use the Selenium Assertions are

Actions,
Assertions, Actions Accessors and
Command, Target, Value and Ino\puts Assertions All of the above
76. The three modes in which we can use the Selenium Assertions are

Assert, assertAssertions,
Assert, Verify and Assery, Verify and VerifyAssertion VerifyAssertions
waitFor Assertions and waitFor and waitFor
77. Following is not the most commonly used Selenium Command?

Open up the browser to


test runner verifyTitle/assertTitle windowsMaximize verifyTable
78. The two ways of discovering the xpath of an element are ?

Firebug and Xpath FireBug and


Checker FireXpath Css and Firebug None of the above
79. Select the locator that can be used to find the most complicated objects in an intrinsic HTML
document?

Xpath Css Input ID


80. Selenium globbing pattern allows only
Dollar symbol
asterisk and character and character
class. asterisk and class. class. None of the above
81. How do you build a locator that is different from the locator type that was recorded?

Locator Selectin
Locator Strategy Locator Guidance Criteria Locator Assistance
82. java.lang.RuntimeException: Could not contact Selenium Server; have you started it? Error
means

You have to stop


the Selenium
You have started the Server and then
You have not started the Selenium Server but need to restart
Selenium Server the port is busy. it All of the above
83. How to extend the build to additional environments using Ant?

Add depends property Add Target Both a and b Only 2


84. The deafult timeout value of recorded command is

3s-30ms 30s-300ms 300s-3000ms 30s-30000ms


85. Why do we use Selenium Client Drivers?

To interact with the


Selenium Server with the Create local selenium
scripts created Web driver script Both a and b None of the above
86. Can we control the speed and pause the test execution in Selenium IDE?

IDE directly
allows you to
IDE provides an slow and fast
IDE provides a slider with option with slow and pointers to
slow and fast pointers to fast pointers to control the
control the speed of control the speed of speed of
execution. execution. execution. None of the above
87. Reference Section of Selenium IDE is used for?

To view the test Description of the Check for


execution commands certain text All of the above
88. How do we add checkpoints manually to our tests in Selenium IDE?

Add Checkpoint Option Reference Section Context Menu Locator Builders


89. storeText

css=input#s

var1

echo

${var1} .
The above code will do?

To check the
Used to store the result Print value in stored value in To check the value
of an evaluation Selenium Ide Selenium IDE of stored text
90. How can we change the test recorded in Xpath to css locator?

Select the element


recorded using
First enable the Xpath, enable the
Using the drop down Using the css selector css selector and css selector and
available next to Find in available next to Find click on find click on the Find
Selenium in Selenium button Button
91. Where do we specify our user javascript extensions in Selenium IDE?

Actions Menu File Menu Options Menu Preference Menu


92. The language of Selenium IDE is?

HTML Java Selenese None of the above


93. the other tool that is available outside Selenium IDE to test the element locator is?

Firefinder Firebug Xpath Getter None of the above


94. the command used to simulate right click on an element in a web page is?

Direct Right click and


simulate the element Use
Locator Command on the web page contectMenu All of the above
95. The command that simulates key stroke key by key is

Type typeKeys typeAndWait None of the above


96. Selenium RC is limited to

Any full fledged


Java Programming Not restricted to any programming
Language language Selenese Language
97. The following are the main components of Selenium RC?

Selenium Server and Client Liraries and


Client Libraries Selenese commands Both a and b None of the above
98. I am not using java to program my tests, do I still have to install java on my system?

Yes No
99. During the execution of the tests I see two windows , one on the test application and the other
showing commands getting executed.How to limit to a single window?

Script in the code to a Specify - Specify - None of the above


singleWindow when
starting Selenium singleWindow in
single window server your script
100. How do you handle recovery scenarios in Selenium?

Recovery Scenario
method Exception Handling Still in progress None of the above
101. Difference between single and double slash in Xpath

Double--Parent, Single – Double--Child,Single


Child —Parent Both a and b None of the above
102. How to handle Ajax controls in Selenium?

Using Wait for


Using wait for condition Using Wait for pageto load
command Command command None of the above
103. How to use Selenium for Performance Testing?

Integrate Load Runner Integrate Jmeter with Integrate Jboss


with Selenium selenium with Selenium All of the above
104. How to check single test method in multiple browsers?

Selenium Web
Selenium IDE Selenium Core Selenium Grid Driver
105. How do you run selenium commands in Slow motion in Selenium RC?

selenium.setSpeed() thread.sleep() Both a and b None of the above


106. the annotations generated with Junit 4 tests in Selenium IDE are

The @Test
The @Before public void The @After public public void
method() void method() method() All of the above
107. Can we include Selenium RC testcases using XMl in TestNG.Justify?

TRUE FALSE
108. What is selenium server default port number?

1111 2222 3333 4444


109. The text pattern types in Selenium are

Globbing regular expressions exact All of the above


110. the input for Client libraries is

Selenium Commands Selenese Commands Selenium Grid None of the above


111. Switching between the multiple instances of the different browsers is not
possible.Justify?

TRUE FALSE
112. How to execute the set of testscripts continuosly in Junit
Parameterization Prioritizing the tests Both a and b None of the above
113. The plug in for Selenium Ide that stores the screen shots automatically on script failure
is

Capture Screen Shot Failed Screen


ScreenShot on Fail plug in Plugin shot Plug in None of the above
114. The sequence of evaluation and flow controls done in Selenium IDE using

Conditional
Looping Constructs Statements User Extensions All of the above
115. The Selenium command to print the two variables in the same line is

StoreVars PutVars GetVars Echo


116. Selenium IDE generates commands using

Keywords Selenium Commands Selenese All of the above


117. Selenium can be integrated with QC using

HP QC ALM11 BlumbleBee Ant Maven


118. Junit comes in built with Eclipse. Justify?

TRUE FALSE
119. The following framework is an instance of the xUnit architecture for unit testing
frameworks

TestNG Junit Hybrid Nunit


120. Does Junit support methods dependency?

Yes No
121. How do you run the Junit tests from the command line?

java java JUnitCore java


org.junit.runner.<test Run Junit <test <test class org.junit.runner.JUnitCore
class name> name> name> <test class name>
122. What is the name of the package that you use for Junit

import
import org.junit.*; import junit.*; package.junit.*; None of the above
123. the syntax to compile a Junit Test Class is?

javac -cp junit- javac -np junit-


javac -cp junit-4.4.jar javac junit-4.4.jar 4.4 4.4.jar
HelloTest.java HelloTest.java HelloTest.java HelloTest.java
124. How do you mark the test method as Junit test method?

Using the JUnit JUnit


annotation JUnit annotation: annotation:
@org.junit.Test. @org.Test. $org.junit.Test. None of the above
125. How does the runner class access the junit test method?
By decalring the By decalring the
By decalring the Junit By decalring the Junit Junit method as Junit method as
method as protected method as private public default
126. All junit Test methods must be declared as

Private Protected Public None of the above


127. Junit reports which one of the failed assertions in a single test?

All Failed
First Failed Assertions Last Failed Assertions Assertions None of the above
128. The Exception: "No runnable methods" occurs when

if you use the


Junit 4 core
if you use the JUnit runner to
if you use the JUnit 4.4 3.4 core runner to execute a class
core runner to execute a execute a class that that has no
class that has no "@Test" has no "@Test" "@Test"
method method method All of the above
129. The following error will pop up if we mix the Junit 3 Testsuite with Junit 4 test classes?

No tests found in the


Assertion Failed error test suite Both 1 and 2 only
130. The following is not the interface of Junit?

Protectable Test TestListener TestFailure


131. The @Test (expected = Exception.class) means

Passes , if the
method does Passes, if the
Fails, if the method does Fails, if the method not throw the method throws
not throw the named throws the named named the named
exception. exception. exception. exception.
132. The Assert method of junit allows you to specify

The Expected
The error message The Actual Result Result All of the above
133. By setting up the instances of object which can be used and configured in your test
methods, Junit can b e

Secure Portable Flexible Modular


134. The following is the use of the annotation in Junit?

Compiler-time
and
Information for the deployment-
compiler Runtime processing time processing All of the above
135. Junit comes in built with Eclipse. Justify?

TRUE FALSE
136. What is the name of the package that you use for Junit

import
import org.junit.*; import junit.*; package.junit.*; None of the above
137. The following elements in your CLASSPATH to run your Junit tests?

JAR files of class


Location of libraries that are
Location of your JUnit testsuites to be required by classes
The JUnit JAR file. test classes. tested. to be tested.
138. How do you mark the test method as Junit test method?

Using the JUnit JUnit


annotation JUnit annotation: annotation:
@org.junit.Test. @org.Test. $org.junit.Test. None of the above
139. Name the mechanism by which you integrate Selenium or junit tests to QC?

Bumblebee Jenkins Hudson All the above


140. The locator that can be used to find the most complicated objects in an intrinsic HTML
document is?

Xpath CSS ID Form


141. What are reference libraries in Selenium?

Selenium 2.20.0 Libs Both a and b None of the above


142. Can we prioritize tests in Junit?

Yes No
143. Junit generates the HTML results report using

Ant Maven Grood One or two


144. We cannot do the following if we use Junit Framework with our Selenium 1 or Selenium
2 scripts

We will not be able to We can define many


define our own reporting reporting formats
format inour own way Both a and b None of the above
145. With Junit the programmer has the disadvantage to

Generate the test


reports in our own Generate the Generate the
Repeat the test designs way logs keywords
146. Junit supports Test Driven Developmet.Justify?

TRUE FALSE
147. What is the order of fastest browser implementation for Web Driver?

HTMLUnitDriver FirefoxDriver IE Driver Non of the above


148. How to interact with hidden elements using Selenium Web Driver?
Hidden Element Locator
Using Java Script Locator Execution Execution
Execution Capabilities Capabilities Caapbilities None of the above
149. The limitation of OS while using Web Driver is?

HTMLUnitDriver,
FFDriver and IEDRiver only on
ChromeDriver on all OS Windows Both a and b None of the above
150. What is the difference between Web Driver and Web Driverbacked in selenium?

Means we need both We need Selenium


Selenium Server and Web Driver and
Selenium Web Driver Remote Web Driver No Difference Both a and b

151. Native Events are to be enabled to perform the following in Selenium Web Driver

For all Actions we


Drag and Drop Switching do in Selenium
Drop Down Actions Actions between frames Web Driver
152. How do you handle other dialogs popped up by the browser like proxy security / script
err

Sikuli AutoIT Java Scripting Selenese


153. Web driver communicates with the application using

Native Language API's Browser API's Both a and b Only 2


154. The following are the advantages of Selenium Web Driver over Selenium 1?

Web Driver directly


Web Driver does not communicates with Web Driver
need the server to be the Native Language supports on all
turned on API's latest browsers All of the above
155. Providing API is a goal of

Web Driver Remote Web Driver Selenium Grid Selenium Core


156. The following is not the driver of Web Driver

InternetExplorer
HTMLUnit Driver Driver Mac Driver Firefox Driver
157. Client and Server are the components of

Remote Web Driver Web Driver


Remote Driver Server Server Server Web Driver
158. What do you use when we want to execute tests on a browser not available locally

Remote Web Driver Selenium TestNG


Server Selenium Grid Selenium Core Framework
159. What is the name of the library we used to record video?

Castro Library Reference Library Web Driver None of the above


Library
160. Selenium will do the following if we try to type or click on the hidden element

Continue with the Pauses the


execution Throw an Exception Throws an error exception
161. Can your JavaScript return to your test?

Yes No
162. Database testing in Selenium is supported by

Both a and b Language Bindings JavaScripts None of the above


163. What is the name of the Testing Framework we used?

Selenium TestNG Robot


Framework TestNG Framework Framework None of the above
164. The following is not the advantages of TestNG Framework

Test that your Independent


code is methods for
Flexible test Embeds BeanShell for multithread application server
configuration. further flexibility. safe. testing.
165. A test method can belong to one or more groups in

Junit Nunit TestNg Nimmble


166. High level framework in Selenium?

Junit and Nunit Robot


TestNG Framework Framework Framework None of the above
167. Where do we add the information about our tests like class name, groups you wish to
run in

build.xml file testng.xml file Both a and b Either a or b


168. The configuration method will be run even if one or more methods invoked previously
failed or skipped.This will happen if we set which attribute to TRUE for the methods.?

inheritGroups alwaysTrue groups fail/skip


169. Name and Parallel are the attributes of which annotation

The
The @BeforeClass The @AfterClass @DataProvider The @Test
170. The annotation whose returned objects are used by TestNG as Test Classes is

The
The @Factory The @Listener @DataProvider The @Parameters
171. The annotation which is the attribute for another annotation is

The @Listener the @BeforeSuite The The @Factory


@DataProvider
172. the attribute which is ignored if the invocationCount is not specified is

invocationTimeOut threadPoolSize Both a and b Only 2


173. The attribute that must be set to false, if we want the methods and classes listed in the
file to be run in an unpredictible order

preserveTest-
preserve-order test=order Order dependsOnMethods
174. TestNG can be invoked in

1)with a testng.xml file

2)with ant

3)From the command line

Only 1, 2 Only 1 Only 2 ,3 All of the above

175. The simplest way to invoke TestNG is

Through
command line
Through command line Through command switches in
switches with atleast one line switches with all combination
xml file the xml files present with ANT All of the above
176. The arguments of the option -configfailureploicy are

directory,methods
Skip and Continue and classes listeners methodSelectors
177. C:> more c:\command.txt

-d test-output testng.xml

C:> java org.testng.TestNG @c:\command.txt

The above syntax is

Placing the command


line switches in a text
file, say
Placing the command line c:\command.txt, and
switches in a text file, say tell TestNG to copy
that file to the
c:\command.txt, and tell testng.xml file to
TestNG to use that file to retrieve its
retrieve its parameters: parameters: Both a and b None of the above
178. What should be used to run several test methods with the same @DataProvider and
you want it to return different values depending on which test method it is supplying data for.

java.lang.Method java.lang.Method
java.lang.reflect.Method java.lang.reflect.Method as the only as the first
as first parameter for as the only parameter parameter for parameter for
@DataProvider for @DataProvider @DataProvider @DataProvider
179. The @DataProvider(name = "dp")

public Object[][] createData(Method m) {

System.out.println(m.getName());

return new Object[][] { new Object[] { "Cedric" }};

Prints the name


of the test
method for two
Prints the name of the Prints the name of of its
test method inside its the test method for @DataProvider
@DataProvider its @DataProvider annotations All of the above
180. The default size of pool of threads, of the parallel data providers running from an xml
file is

1 11 10 100
181. TestNG allows you to specify the dependencies in

annotations and xml file xml file attributes Annotations


182. All the methods you depend on must have run and succeeded for you to run. If at least
one failure occurred in your dependencies, you will not be invoked and marked as a SKIP in the
report.

Soft Dependencies Hard Dependencies Both a and b Only 2


183. The following is obtained by adding alwaysRun=true in your @Test annotation

methodDependency Soft Dependency invocationCount dependsOnMethods


184. the order of invocation for methods that belong in the same group is not guaranteed to
be the same across test runs.Justify?

TRUE FALSE
185. The methods are marked as Skip rather than Fail when
A method 186.
depended upon A method
A method depended fails and you depended upon
A method depended upon Skips and you have a hard fails and you have
upon Skips and you have have a soft dependency on a soft dependency
hard dependency on it dependency on it it on it 186.

By default the dependent methods are grouped by


methodDependency ClassDependency Invalid Option Classes
187. How to create tests dynamically in TestNg

The
The @DynamicTest The @Factory @DataProvider
annotation annotation annotation The @Dynamic
188. How to to create a test method that will access a page on a Web site several times, and
you want to invoke it with different values?

Using @DataProvider Using @DynamicTest Using @Factory


annotation annotation annotation None of the above
189. The Class level annotation in Selenium is

The @BeforeClass The @AFterClass The @Test The @Class


annotation annotation annotation annotation
190. The interface which modifies the behaviour of TestNG are

The
The @Listener The @Modifier @TestNGModifier None of the above
191. Name the file that Is created to store the results of the test run?

The output-
The index.htm file The index.html file report file Both 1 and 3
192. Does TestNg support dependency in XML.Justify?

TRUE FALSE
193. The following is not the core concept of AnT?

Targets A build file with


XML format Decalrative Format conatining Tasks many projects
194. The java based build tool designed to be cross platform, extensibe and scalable is

ANT MAVEN
195. Ant address the deployment problems of java project such as

FTP, Telnet Application Servers SQL Commands All of the above


196. Advantages of Ant 1.7.1 are

Support for java6 Support for


Bug fix release features javaFX All of the above
197. Is there a property file for plug in configuration in Maven 2.0.Justify?

Yes No
198. The command that determines which POM contains missing transitive dependency is

run "mvn -X" run "maven -x" run "Maven -x" All of the above
199. MOJO stands for

Maven plain Old Java Maven Old Java


Object Object Both a and b None of the above
200. How can we use Ant tasks in Maven 2?

Using the
instructions in
the Ant
Using Ant Plugin Using AntRun plugin documentation All of the above
201. Maven Repository types

Public Remote External Private Remote


repository External repository Local repository All of the above
202. A high level, intelligent project management, build and deployment tool provided by
Apache's Software Foundation group is

Ant Maven Both a and b Only 1


203. What is the command required to start the Hub?

ant launch-hub
ant launch-hub ant launch -hub Selenium_Grid None of the above
204. http://nameofmachine:4444/console means

We can see the


We can see the name name of the
We can see what is of the machine local host
happening on the grid running the grid running the grid All of the above
205. how do you specify the port the Remote Control is running on?

– –
–port:DportNumber –Dport:portNumber Dport:=portNumber Dport=portNumber
206. –Denvironment=target means

Specifying which
Specifying which environment
Specifying which browser environment you you would like
you would like the would like the the remote
remote control to be remote control to be control to be
registered with registered with run with Only 1 and 3
207. What does grid2 mean

Grid for only


Grid for both Selenium 1 Grid for only Selenium Web Grid for Selenium
and Web Driver Selenium 1 Driver Grid
208. Extending Selenium RC to to distribute to your tests across multiple servers , Saving time
by running the test I parllel is the functionality of

Robot
Selenium Core Selenium Grid Selenium TestNG Framework Framework
209. The components of Selenium that are used for recording are

Selenium RC Selenium Core Selenium IDE Both 1 and 2


210. The reasons to use the Selenium-Server with Selenium-WebDriver are
You are not
You want to connect using the Java
to a remote machine bindings (i.e.
You are using Selenium- that has a particular Python, C#, or
Grid to distribute your browser Ruby) and
tests over version that is not on would like to
multiple machines or your current use HtmlUnit
virtual machines (VMs) machine. Driver All of the above
211. Chnaging User agent in Selenium Web Driver is easy with the browser

Internet Explorer Safari Google Chrome Mozilla Firefox


212. Page Object Design Pattern of your test code in Selenium Web Driver is possible with

Object Factory Page Object Designs Page Factory Any of the above
213. Does Selenium Web Driver be able to handle requests for IE / Chrome without
additional modifications.Justify?

TRUE FALSE
214. The Advance User Intercations in Selenium Web Driver require --------------- to be
anabled

User Events Native Language API's Native Events Any of the above
215. How does web driver support JavaScript alerts and prompts

Using Native
Using Alert API's Using Alerts Api's None of the above
216. File Uploads in Selenium is supported by

Selenium Web Selenium Remote


Selenium Grid Selenium Core Driver Web Driver
217. The design pattern that test automation uses for enhancing test maintenance and
reducing code duplication.

Flowchart
Model Based Page Object Designs Model None of the above
218. The purpose of UI Map is to make ----------- easier.

Test Script
Test script enhancement Test Script Hosting Management TestScript Creation
219. The best way to locate and verify an Ajax element is to use

Selenium Web Driver Selenium Grid


Selenium RC API API API Any of the above
220. which of the following is the Safe Operation in Selenium

to check for presence of


an element on page
before carrying out some Wrapping Selenium
operation. Calls Both a and b Only 1
221. Page Objects themselves should never should make assertions and verifications.Justify?
TRUE FALSE
222. The type that can be applied to several java elements in Selenium is

Selenium Type Selenium Method Annotation None of the above


223. The ---------- allows access to headlessHTMLUnit can allow really fast tests

Selenium Web
Selenium IDE Selenium RC Selenium Grid Driver
224. The type of Selenium that is less prone to error and browser configuration is

Selenium RC Selenium Web Driver Selenium Grid Selenium COre


225. The Xpath Checker will install by install from Firefox->Addons.Justify? TRUE
226. The ---------- is used to embed Selenium Core internally.

Selenium Web
Selenium IDE Selenium RC Driver Selenium Grid
227. Selenium Core is bounded to

Same Origin Policy of


Java Script Policies Selenium Both a and b Either a or b
228. The number of sections in Selenium Core are

2 3 8 5
229. Which of the following is not the section of Selenium Core

TestSuite Current Test Control Panel Editor


230. Selenium Core provides an additional mechanism for running automated tests,the name
of the mechanism is

Automated Test
HTA mode. Selenium Core Mode Mode None of the above
231. HTA Mode of Selenium Core works on the ---------- browser

Internet
Firefox Google Chrome Explorer Safari
232. The annotation used by Page Object Design Pattern for object identification is

The @Identify The @FIndBy The @FindBys Both 2 and 3


How does Selenium EasyAutomate handle proxy?

Using Sikuli Using Proxy Settings Using AutoIT None of the above
233. What was the need for Selenium EasyAutomate?

Automation
Selenium requires users scripts & test
to know about any one of specifications
the programming Selenium does not are kept as
language like java, ruby, provide testcase different test
python etc. PASS/FAIL status. artifacts All of the above
234. The following can be embedded into the Test Specification in Selenium EasyAutomate:

Automation
Automation Automation Testcase
Automation Keywords Commands Scripts Specifications
235. The parameters used to define the scripting environment are

Test_Environment Module_Under_Test Application_Under_Test All of the above


236. The video support that is needed for Selenium EasyAutomate is

EasyAuotmate Video
Xuggle Support WebEx None of the above
237. Image verification is done through

Any 3rd party


AutoIT Sikuli tools All of the above
238. Selenium EasyAutomate load the test data from excel using

Application
Application Under Under Test and Application Under
Application Under Test Test and Test Module Under Test and Software
and Test Environment Environment Test Release
239. Selenium EasyAutomate framework loads the test specification from excel using

Application Under Test Application Under Application Software Release


and Test Environment Test and Module Under Test and and Test
Software
Under Test Release Environment
240. CreateBrowser keyword uses the Browser_Type in which of the following file to create
the browser

environment.conf log4j Application Evvironment


241. Difference between OPEN "http://www.yahoo.com" and OPEN
"http://www.yahoo.com" "0" is

Both
No Difference. first one opens the browser given and a
Both will open the second one opens the given browser and
browser given. with boolean value 0 b None of the above
242. Maximum time to wait for a text is configured as what in the cofig file?

ELEMENT_LOAD_WAIT_PER WAIT_FOR_ELEME ELEMENT_WAIT_LOAD_PER WAIT_FOR_ELEME


IOD NT IOD NT
243. The keyword used to set the browser active and to execute the rest of the commands in
that browser is

SetActive="BrowserName" SetBrowserActive SetActiveBrowser SetBrowser


244. The keyword used to work with drop down is

SelectWindow By
Drag and Drop Select Select Window partial
245. The command for which there is no wait time is

VerifyImageNotPresent VerifyImagePresent Both a and b None of the above


246. How do we type the given text on the focussed element

Using Selenium using


Using AutoIt Using Sikuli EasyAutomate TypeOnFocussedElement
247. The keyword used for string comparision is

TextPresent="status
ISTextPresent VerifyTextPresent " None of the above
248. The keyword used to store the current browsers title into a variable given is

StoreTitle StoreBrowserTitle StoreTitleByVar All of the above


249. The keyword used to wait for the page load in the browser window to complete Is
Delay WaitForPageLoad WaitForPageToLoad WaitForPAge
250. When will the uncheck keyword returns Success?
When the
element is
When the element is When the element is found at the Never returns
already TurnedOff Turned On page Success
251. The results in Selenium EasyAutomate are viewed using
Results Viewer Results ID Run iD None of the above
252. The keyword command editor has
Environment Application Testcase All of the above
253. The xpaths for the objects are given in
Environment tab Application Tab Testcase Tab None of the above
254. The input for the objects is given in
Application Tab Env Global Tab Testcase Tab Script Editor
255. How will you pause the execution?
By using "DELAY" By using "Wait"
keyword. keyword Either 1 or 2 None of the above
256. What is "CLOSE" keyword?
Closes the default Closes the
Close all the browsers browser. Browser API None of the above
257. The result of the groovy scripts is logged in the ----- files
html files jpeg files xml files None of the above
258. Why do we use groovy scripting in Selenium EasyAutomate?
To give values for
To handle dynamic dynamically changing
validations in a page elements in the page Both a and b None of the above
259. How do we display the run time values in Selenium EasyAutomate?
Using Groovy Using Java
Using Sikuli Using AutoIt Scripting Scripting
260. The command used to execute the groovy script is
InvokeMethod InvokeScript InvokeGroovyScript InvokeGroovyMethod
261. String comparision In Selenium EasyAutomate is
Case Sensitive Not Case Sensitive Only 1 Only 2
262. EasyAutomate using Selenium provides development of test specification using its
IDE.Justify? TRUE
263. The format used by EasyAutomate to export the test specifications is

Microsoft Word Excel CSV PDF


264. The default address in which the Selenium server will start is

Throws Error
Local Host 128.0.0.1 Message None of the above
265. The parameter that needs to be updated for changing the browser in which the tests are
to be done is

Browser Browser_URL TYPE_BROWSER BROWSER_TYPE


266. The parameter that needs to be updated for changing the application URL to be tested
is

SITE_URL INDEX_URL URL


267. The extension for the Sequence file is

TSF TSQ BAT SH


268. The platforms in which the easyAutomate Selenium will work

Windows and
Windows Mac Mac Linux
269. EasyAutomate Selenium supports runtime validations.Justify? TRUE
270. The languages supported in Selenium EasyAutomate are

Groovy Python Groovy and Java Groovy and Ruby


271. The keyword used to execute the Groovy script from the Keyword Script in Selenium
EasyAutomate is

INVOKEMETHOD INVOKESCRIPT INVOKE_SCRIPT None of the above


272. The keyword used to call the java method from the Keyword Script in easyAutomate
Selenium is

INVOKEMETHOD INVOKESCRIPT INVOKE_SCRIPT None of the above


273. The class format in which the easyAutomate Selenium looks for java methods is

com.3rdparty.wrappers com.thirdparty.wrappers com.thirdparty.wrapper None of the above


274. The environment variable used to load the 3rd party java libraries is

APPLICATION_UNDER_TES
MODULE_UNDER_TEST T BROWSER_TYPE None of the above
275. Selenium easyAutomate supports executing the test scripts im multiple browsers
without modifying the scripts.Justify? TRUE
276. The easyAutomate need to be restarted after the Scripting Environment Is
loaded.Justify? TRUE
277. The keyword used to pause the execution for a specified time is

DELAY CLICKANDWAIT WAITFORALERT WAITFORCONFIRMATION


278. Sikuli is used to type the given text for the command

TYPEONFOCUSSEDELEMEN DOUBLECLICKIMAG
T CLICKIMAGE E None of the above
279. The following two are displayed at the bottom right of the screen when we are
automating the testcases in easyAutomate Selenium?

BROWSER_TYPE
AUT and Browser and Browser
AUT and Module Name Name Name None of the above
280. We can import Selenium IDE Commands to our EasyAutomate.Justify? TRUE
281. The following is used to execute the Selenium script in multiple browsers at the same
time

Test
Specification
Scripter Test Sequence Editor Editor Test Executor
282. The execution mode where the tests configured in the TSQ shall be started in selected
browsers in parallelis

Sequence Execution Parallel Execution


Mode Mode Both a and b None of the above
283. Which of the browser property is compared with, in the cross browser testing in
Selenium EasyAutomate?

Browser UI Browser_URL BrowserName None of the above


284. The following should be performed when exporting the results from Selenium
EasyAutomate

Dashboard Viewer Compare Runs Both a and b None of the above


285. The key fields of Dashboard viewer are

Run Id Browser Name Exceuted On All of the above


286. The following is not the part of log view

Script Log Execution Log Results Log None of the above


287. The groovy files are grouped based on

Application
Application Under Under Test and
Application Under Test Test and Software Module Under
and Test Environment Release Test None of the above
288. The command used to launch the Selenium EasyAutomate IDE is

CBV.bat r.sh r.bat cms.bat


289. How many Parameters needs to be passed for the keyword "PASTETEXT"?

2 3 4 6
290. What is the Function of the keyword "CLEARFORMELEMENT"?

Clears the text


Clears the element Clears the username of all the
text editbox. elements None of the above
291. How do you type a text in a given element?

By using "TYPEKEYS" By using "TYPEKEY" By using "TYPE"


keyword. keyword. keyword. Any of the above
292. How do you load URL in a browser?

OPEN
OPEN SITE_URL, "1" OPEN SITE_URL "SITE_URL" "1". Any of the above
293. Which keywords can have unlimited parameters?

INVOKESCRIPT REPORTTEXT. Both a and b None of the above


294. The ------- simulates the typing of keys using Groovy in Selenium.

simulate TypeKeys Type None of the above


295. The command used to store the text displayed in the confirmation dialog box into the
given variable.

storeConfirmationTextCounts storePromptText stoteConfirmation storeConfirmationText


296. What is "CAPTURESCREENSHOT" Keyword?
Captures the currently Captures the
loaded browser's view Captures the all the specifued screen
into the file. browser's views shot All of the above
297. How many parameters can be passed to "SELECT" keyword?

4 5 6 7
298. Give the Syntax for typing a text?

TYPEKEYS
TYPEKEYS "path" "text". TYPEKEYS "PATH" "TEXT" None of the above
299. How do you make Firefox as Active Browser?

BrowserName="firefox Browser.Activte="firefox SETACTIVEBROWSE SetActiveBrowser="firefox


" " R "firefox". "
300. What is "SELECTFRAME" keyword?

Select the frame


configured as
Selects the frame FRAME_TOP in the
identified by top. configuration Both a and b Only 1
301. How do you uncheck an option?

UNCHECK
"//input[@type='checkbox'] UNCHECK
" //input[@type='checkbox']" "checkbox" "1" Any of the above
302. What is the use of "STOREFORMELEMENT" keyword?

Stores the value


only of only the
Any form input element's Gets the value of the element
value could be stored in edit box and stores it specified in the
the given variable. in a variable configuration All of the above
303. How will you Refresh the current window?

By using
"REFRESH
By using "REFRESH" By using "REFRESH =WINDOW
keyword. CURRENT WINDOW" NAME" None of the above
304. What is the parameter for "WAITFORPAGELOAD"

0 1 2 3
305. what is "ASSERTVARWITHELEMENTVALUE" keyword?

Compares the
input element
Any form input element's Gets the input and variable
value could be compared element value with values and
with the given variable's the value given in the returns the
value. variable result All of the above
306. What is "STOREPROMPTTEXT" keyword?
Captures the
Captures the prompt message
Captures the prompt prompt message displayed by
message displayed by displayed by Selenium Easy
javascript into the Shows the captured groovy script Automate into the
variable. message as a variable into the variable variable
307. Give the Syntax for "DELAY"?

DELAY
DELAY "time" "KNOWN_DELAY" "1" Both a and b None of the above
308. How many parameters are there for the keyword "DOUBLECLICK"?

1 2 3 4
309. What is "storeXpathcount" keyword?

Used to get the To get the


Stores the count of the number of similar number of Stores all the
given element into the elements found in xpaths in the xpath's into the
given variable. the parent element. page specified. variable
310. What is "STORETEXTINVARIABLE" keyword?

Gets the text for the Gets the text for


given element and all the elements
Gets the text for the stores it in the and stores it in
given element and stores variable specified in the variables
it in the given variable. the configuration file. specified. None of the above
311. What is "DEBUGVARIABLE" keyword?

Displays the given


variable value into the Used to know the Same as Debug
log. given variable's value keyword All of the above
312. What is "CLOSE" keyword?

Closes the
Selenium
Closes the default Closes the current Closes all the EasyAutomate
browser. browser browsers window
313. What is "WAITFORTEXT" keyword?

Waits for the text in a


Waits for the text that is page that is present
present in the current in the configuration
browser page. file Both a and b None of the above
314. Give the syntax for "STOREPROMPTTEXT" keyword?

STOREPROMPTT
STOREPROMPTT EXT "parameter" STOREPROMPTTEXT="param STOREPROMPTTEXT="param
EXT "parameter" "1" eter" eter" "1"
315. How many parameters can be passed for the keyword "TYPE"?
3 4 1 2
316. Explain the function of "DELAY" keyword?

Pauses the execution Pauses the


Pauses the execution for for the given amount execution for
the given amount of of time in the the time given if
time. configuration file the testcase fails None of the above
317. How many parameters can be passed for the keyword "UNCHECK"?

2 1 4 0
318. What is the function of "ASSERTELEMENTVALUE" ?

Asserts the
Asserts whether the given element
given element's value value with the
Asserts whether the is same as the given value given in Asserts all the
given element's value is element value and the element's values
same as the value given returns the value as configuration and returns the
or not. well file values
319. What is the use of "WAITFORCONFIRMATION" keyword?

Waits for the Waits for the


confirmation dialog to confirmation
appear on the browser. keyword to execute Both a and b None of the above
320. What is the Function of the Keyword "TYPEKEYS"?

Types the given


text into the
input field as
configured in
Types the given text in the
the given input element Types the given text configuration
via one-by-one character. as a whole file None of the above
321. What is "STOREALERTTEXT" keyword?

Captures the
alert message
Captures the alert displayed by
message displayed by Uses the alert() groovyscript Captures all the
javascript into the function to capture into the alert texts into a
variable. the text message variable. varaible
322. What is "WAITFORALERT" keyword?

Wait for the alert to Waits till the


Waits for the alert to appear on the default alert displays in
appear on the browser. browser all the browsers Any of the above
323. What is "REPORTTEXT" keyword?

Reports the given text It uses the Groovy It logs the text All of the above
into the excel comments
column for the running script to display the into the
test step. runtime values execution log.
324. How will you use "STOREALERTTEXT" keyword?

STOREALERTTEXT STOREALERTTEXT STOREALERTTEXT


"alertmsg" "path" "alertmsg" "path" "1" "alertmsg" None of the above
325. How will you use "WAITFORCONFIRMATION" keyword?

WAITFORCONFIRMA WAITORCONFIRMATION="me WAITFORCONFIRMATION("msg", Any of


TION ssage" "time") the above
326. The correct syntax of "SELECTFRAME" keyword is?

SELECTFRAME SELECTFRAME SELECTFRAME


"parameter" "Frame_Top" "1" "Frame_Top" None of the above
327. What is "PAGEDOWN"?

Simulates the
Simulates the page page down only
down only if the if the current
Simulates page down in current browser is browser is in
the current browser active forground All of the above
328.

You might also like