diff options
author | Viktors Tjarve <viktors.tjarve@zabbix.com> | 2018-03-26 17:13:58 +0300 |
---|---|---|
committer | Viktors Tjarve <viktors.tjarve@zabbix.com> | 2018-03-26 17:13:58 +0300 |
commit | f9163953e316ed19dabfc590b6a35097c584d816 (patch) | |
tree | c661328c7ed616597bb3697f31bfd0b4fb8907ec /build-backend.xml | |
parent | e97c5011a02e6b79aaee1e6abc3fbe8eb07c1b01 (diff) |
.......... [DEV-810] added multiple configuration options to mock-test target for Jenkins build
Diffstat (limited to 'build-backend.xml')
-rw-r--r-- | build-backend.xml | 45 |
1 files changed, 29 insertions, 16 deletions
diff --git a/build-backend.xml b/build-backend.xml index f196603287c..cc14d140753 100644 --- a/build-backend.xml +++ b/build-backend.xml @@ -275,23 +275,36 @@ <!-- Build Zabbix with all supported databases --> <target name="make-db" depends="make-db-mysql,make-db-postgresql,make-db-oracle,make-db-db2"/> - <target name="mock-tests"> - <!-- Build Zabbix server and proxy with C mock tests --> + <target name="mock-tests" depends="init-conf-options"> + <!-- Build Zabbix with C mock tests --> <exec executable="./bootstrap.sh" failonerror="on"></exec> - <exec executable="./configure" failonerror="on"> - <arg line="-q"/> - <arg line="--enable-server"/> - <arg line="--enable-proxy"/> - <arg line="--enable-agent"/> - <arg line="--with-mysql"/> - <arg line="--with-libxml2"/> - </exec> - <exec executable="make" failonerror="on"> - <arg line="-s"/> - <arg line="-j5"/> - <arg line="tests_build"/> - </exec> - <exec executable="tests/tests_run.pl" failonerror="on" output="output.xml"></exec> + <propertyselector property="conf.list" delimiter="," match="conf(\d+)"/> + <sortlist property="conf.list" delimiter="," value="${conf.list}" override="true"/> + <for list="${conf.list}" param="name" delimiter=","> + <sequential> + <exec executable="./configure" failonerror="on"> + <arg line="-q"/> + <arg line="${@{name}}"/> + </exec> + <trycatch> + <try> + <exec executable="make" failonerror="on"> + <arg line="-s"/> + <arg line="-j5"/> + <arg line="tests_build"/> + </exec> + <exec executable="tests/tests_run.pl" failonerror="on" output="output.xml"></exec> + </try> + <finally> + <exec executable="make" failonerror="on"> + <arg line="-s"/> + <arg line="-j5"/> + <arg line="clean"/> + </exec> + </finally> + </trycatch> + </sequential> + </for> </target> <target name="run-unit-test"> |