Here is the sample script which will open a page...
This script was written using JUnit...
import org.junit.After;
import org.junit.Before;
import org.junit.Test;
import org.openqa.selenium.server.SeleniumServer;
import com.thoughtworks.selenium.DefaultSelenium;
import com.thoughtworks.selenium.SeleneseTestCase;
import com.thoughtworks.selenium.Selenium;
public class Google1 extends SeleneseTestCase{
private Selenium selenium;
private SeleniumServer seleniumServer;
@Before
public void setUp() throws Exception {
selenium = new DefaultSelenium("localhost", 4444, "*iehta", "http://");
seleniumServer = new SeleniumServer();
seleniumServer.start();
selenium.start();
}
@Test
public void testText1() throws Exception {
selenium.open("http://www.yahoo.com");
selenium.windowMaximize();
}
@After
public void tearDown() throws Exception {
selenium.stop();
seleniumServer.stop();
}
}
December 13, 2010
Sample script using JUnit
Tags
# JUnit
# Sample script
About Naga
Soratemplates is a blogger resources site is a provider of high quality blogger template with premium looking layout and robust design. The main mission of templatesyard is to provide the best quality blogger templates.
selenium RC
Labels:
JUnit,
Sample script,
selenium RC
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment