Running xml file from commandline

When working in IntelliJ 12 to write selenium webdriver tests I uses a suite xml file to run some tests and I just right click on the file and select Run to run the xml file. How do we run the same file from command line?

My suite file looks like this -

<!DOCTYPE suite SYSTEM "">
<suite name="Suite" parallel="methods">
    <test name="Images in featured rotator block" parallel="false">
        <parameter name="BROWSER" value="FF" />
        <parameter name="VERSION" value="21" />
        <parameter name="PLATFORM" value="MAC" />
            <class name="imageTest.featuredRotator"/>

the parameters from the suite file are passed to a base class which sets the desired capabilites and the command I am using to run the suite file is mvn test -DsuiteFile=resources/test-suites/audioSuite.xml. The test runs but nothing happens

1 comment
Comment actions Permalink


here is a way how to start testng through ant
here is the documentation for maven


Please sign in to leave a comment.