Sunday, 15 May 2011

How to run java file exported from selenium IDE through command prompt in windows -



How to run java file exported from selenium IDE through command prompt in windows -

can 1 tell me how can run java file exported selenium ide through command prompt.

i have used next command: "java -jar selenium-server.jar -htmlsuite "*firefox" "http://www.google.com" "c:\mytestsuite\mytestsuite.html" "c:\mytestsuite\results.html"

able launch selenium functional test runner nil executed there.

the converted tests junit tests. should have 2 processes:

your selenium server process:

java -jar lib/selenium-server-standalone-2.28.0.jar junit test runner

"java -cp /usr/share/java/junit.jar org.junit.runner.junitcore [test class name] " if have several test classes, might improve create testsuite suite annotation:

@runwith(suite.class) @suiteclasses({ mytestclass1.class, mytestclass2.class}) public class testsuite { ...

if using spring, can setup config containing selenium server address, browser, ...

@runwith(springjunit4classrunner.class) @contextconfiguration(locations = { "classpath:my/package/seleniumconfig.xml"}) public abstract class seleniumtestsuite {

java selenium command-line selenium-webdriver

No comments:

Post a Comment