wood burning stoves 2.0*
The moose likes Web Services and the fly likes How to run selenium testclasses parallel using selenium grid and maven Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Web Services
Bookmark "How to run selenium testclasses parallel using selenium grid and maven" Watch "How to run selenium testclasses parallel using selenium grid and maven" New topic
Author

How to run selenium testclasses parallel using selenium grid and maven

kalyani kota
Greenhorn

Joined: Jun 06, 2010
Posts: 3
Hi,

We are currently executing the Selenium test cases using maven. We have around 150Tc’s and divided them in 4 Testclasses. Now we want run these testclasses parallel using selenium grid.

My testclasses is as below:

@BeforeClass
public static void configureClassElements() {

try {
ServerSocket serverSocket = new ServerSocket(port);
serverSocket.close();
RemoteControlConfiguration rcConfig = new RemoteControlConfiguration();
rcConfig.setPort(port);
SeleniumServer server = new SeleniumServer(rcConfig);
server.boot();
server.start();
} catch (Exception e) {
e.printStackTrace();
}

}
@Test
public void testSearch() throws Exception {
selenium.open("/");
selenium.select("requestID", "label=Request ID");
selenium.type("inputText", "471");
selenium.click("go");
}
@BeforeMethod
public void configureSelenium() {
selenium = new DefaultSelenium("localhost", port, browser, url);
selenium.start();
}
@AfterMethod
public void destroyTest() {
try {

selenium.close();
selenium.stop();
} catch (InterruptedException e) {
e.printStackTrace();
}

}

In web I got dependency for grid in pom.xml as below:
<dependency>
<groupId>org.seleniumhq.selenium.grid</groupId>
<artifactId>selenium-grid-tools</artifactId>
<version>1.0.5</version>
</dependency>


How to register different rc’s to hub?


Can anybody help me, how to use selenium grid in our testclasses with maven.

Thanks in advance..
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to run selenium testclasses parallel using selenium grid and maven
 
Similar Threads
JSF 2 - Problem with ManagedBean
java.util.MissingResourceException: Can't find bundle for base name in JSF Spring Maven project
how do i send a email test report from maven
Incorrect hibernate version or maven ignore and didn't download hibernate jar file.
Could not resolve dependencies