forked from bcotton/selenium-grid
-
Notifications
You must be signed in to change notification settings - Fork 32
/
Copy pathbuild.xml
executable file
·101 lines (89 loc) · 3.97 KB
/
build.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
<project name="Selenium Grid Remote Control" default="package-standalone" basedir=".">
<description>Selenium Grid Remote Control</description>
<property name="rootdir" value="${basedir}/.."/>
<property file="${rootdir}/project.properties"/>
<property name="name" value="Selenium Grid Remote Control"/>
<property name="artifact" value="selenium-grid-remote-control"/>
<property name="version" value="SNAPSHOT"/>
<property name="selenium.version" value="Set Me"/>
<import file="${rootdir}/lib/build/common-build.xml" />
<path id="compile.classpath">
<fileset dir="${rootdir}/vendor">
<include name="selenium-server-${selenium.version}-standalone.jar"/>
</fileset>
<fileset dir="${rootdir}/vendor">
<include name="commons-httpclient-3.1.jar"/>
<include name="commons-codec-1.4.jar"/>
<include name="commons-logging-1.1.1.jar"/>
</fileset>
<pathelement location="${rootdir}/infrastructure/core/target/classes"/>
<pathelement path="${java.class.path}/"/>
</path>
<path id="runtime.classpath">
<fileset dir="${rootdir}/vendor">
<include name="selenium-server-*.jar"/>
</fileset>
<!-- Selenium Server must be first in classpath -->
<fileset dir="${dist}/lib">
<include name="selenium-grid-remote-control-standalone-${version}.jar"/>
</fileset>
<pathelement path="${java.class.path}/"/>
</path>
<target name="package-standalone" depends="package" description="Package as a jar including all dependencies">
<package-standalone-jar main-class="com.thoughtworks.selenium.grid.remotecontrol.SelfRegisteringRemoteControlLauncher">
<dependencies>
<zipfileset src="${rootdir}/infrastructure/core/target/dist/lib/selenium-grid-core-${version}.jar"/>
<zipfileset src="${rootdir}/vendor/jetty-6.1.24.jar"/>
<zipfileset src="${rootdir}/vendor/jetty-util-6.1.24.jar"/>
<zipfileset src="${rootdir}/vendor/servlet-api-2.5-20081211.jar"/>
<zipfileset src="${rootdir}/vendor/commons-httpclient-3.1.jar"/>
<zipfileset src="${rootdir}/vendor/commons-codec-1.4.jar"/>
<zipfileset src="${rootdir}/vendor/commons-logging-1.1.1.jar"/>
</dependencies>
</package-standalone-jar>
</target>
<property name="host" value="localhost"/>
<property name="port" value="5555"/>
<property name="hubURL" value="http://localhost:4444"/>
<property name="environment" value="*firefox"/>
<property name="hubPollerIntervalInSeconds" value="30"/>
<property name="seleniumArgs" value=""/>
<target name="run" description="Launch a remote control">
<java classpathref="runtime.classpath"
classname="com.thoughtworks.selenium.grid.remotecontrol.SelfRegisteringRemoteControlLauncher"
fork="true"
failonerror="true">
<sysproperty key="http.proxyHost" value="${http.proxyHost}"/>
<sysproperty key="http.proxyPort" value="${http.proxyPort}"/>
<sysproperty key="https.proxyHost" value="${https.proxyHost}"/>
<sysproperty key="https.proxyPort" value="${https.proxyPort}"/>
<arg value="-port"/>
<arg value="${port}"/>
<arg value="-host"/>
<arg value="${host}"/>
<arg value="-hubURL"/>
<arg value="${hubURL}"/>
<arg value="-env"/>
<arg value="${environment}"/>
<arg value="-hubPollerIntervalInSeconds"/>
<arg value="${hubPollerIntervalInSeconds}"/>
<arg line="${seleniumArgs}"/>
</java>
</target>
<target name="run-echo" description="Launch a echo remote control">
<java classpathref="runtime.classpath"
classname="com.thoughtworks.selenium.grid.remotecontrol.instrumentation.EchoRemoteControl"
fork="true"
failonerror="true">
<arg value="-port"/>
<arg value="${port}"/>
<arg value="-host"/>
<arg value="${host}"/>
<arg value="-hubURL"/>
<arg value="${hubURL}"/>
<arg value="-env"/>
<arg value="${environment}"/>
<arg line="${seleniumArgs}"/>
</java>
</target>
</project>