Find file
Fetching contributors…
Cannot retrieve contributors at this time
76 lines (65 sloc) 2.41 KB
<project name="Kryptonite" default="test" basedir=".">
Easily run Selenium tests on Selenium GRID
<!-- set global properties for this build -->
<property name="src" location="src" />
<property name="build" location="build" />
<property name="dist" location="dist" />
<property name="lib" location="lib" />
<property name="tests" location="test" />
<property name="reports" location="reports" />
<path id="lib.path">
<fileset dir="${lib}">
<!--<include name="**/*.jar" />-->
<include name="**/guava-r09.jar" />
<include name="**/junit-4.8.2.jar" />
<include name="**/parallel-junit.jar" />
<include name="**/selenium-java-2.0rc3.jar" />
<include name="**/selenium-server.jar" />
<pathelement path="${build}" />
<target name="help">
<echo>Available Commands: test, compile, clean, dist</echo>
<target name="clean" description="clean up">
<!-- Delete the ${build} and ${dist} directory trees -->
<delete dir="${build}" />
<delete dir="${dist}" />
<delete dir="${reports}" />
<target name="init" depends="clean">
<!-- Create the time stamp -->
<tstamp />
<!-- Create the build directory structure used by compile -->
<mkdir dir="${build}" />
<!-- Create the distribution directory -->
<mkdir dir="${dist}/lib" />
<mkdir dir="${reports}" />
<target name="compile" depends="init" description="compile the source ">
<!-- Compile the java code from ${src} into ${build} -->
<javac srcdir="${src}" destdir="${build}" classpathref="lib.path" includeAntRuntime="false" debug="true" />
<target name="dist" depends="compile" description="generate the distribution">
<!-- Put everything in ${build} into the MyProject-${DSTAMP}.jar file -->
<jar jarfile="${dist}/lib/MyProject-${DSTAMP}.jar" basedir="${build}" />
<target name="test" depends="compile" description="running selenium tests">
<echo>Running all selenium tests...</echo>
<classpath refid="lib.path" />
<formatter type="plain" />
<test name="com.brk.testsuite.AllTests" haltonfailure="no" outfile="result" todir="${reports}">
<formatter type="xml" />
<batchtest fork="yes">
<fileset dir="${tests}">
<!-- <exclude name="**/*Test*.java" /> -->
<include name="./build/com/brk/testsuite/" />