The following commit has been merged in the master branch: commit b26718d6b2f4b91350a4cccf1472245aa5b8de22 Author: James Page <james.p...@canonical.com> Date: Thu Oct 27 13:42:26 2011 +0100
Enabled C and Java test suites: * Enabled C and Java test suites: - d/control,d/compat: Bumped debhelper compat level to 8 to allow arch/indep overrides. - d/rules: Enable test suites for -arch and -indep builds. - d/patches/debian/patch-build-system: Patch unit testing to exclude InvalidSnapshot and Upgrade tests (non-free data) and to pickup junit4 from system library. diff --git a/debian/changelog b/debian/changelog index 23527d6..9dfe1ab 100644 --- a/debian/changelog +++ b/debian/changelog @@ -5,8 +5,15 @@ zookeeper (3.3.3+dfsg2-3) UNRELEASED; urgency=low upstart configuration if required. - d/ubuntu|debian_control_vars,d/control,d/rules: Provide different Depends for zookeeperd package when building under Ubuntu/Debian. - - -- James Page <james.p...@ubuntu.com> Thu, 27 Oct 2011 10:23:37 +0100 + * Enabled C and Java test suites: + - d/control,d/compat: Bumped debhelper compat level to 8 to allow + arch/indep overrides. + - d/rules: Enable test suites for -arch and -indep builds. + - d/patches/debian/patch-build-system: Patch unit testing to exclude + InvalidSnapshot and Upgrade tests (non-free data) and to pickup + junit4 from system library. + + -- James Page <james.p...@ubuntu.com> Thu, 27 Oct 2011 12:57:26 +0100 zookeeper (3.3.3+dfsg2-2) unstable; urgency=low diff --git a/debian/compat b/debian/compat index 7f8f011..45a4fb7 100644 --- a/debian/compat +++ b/debian/compat @@ -1 +1 @@ -7 +8 diff --git a/debian/control b/debian/control index 2f617ac..533d717 100644 --- a/debian/control +++ b/debian/control @@ -9,9 +9,10 @@ Vcs-Git: git://git.debian.org/pkg-java/zookeeper.git Standards-Version: 3.9.2 Build-Depends: ant (>= 1.6.0), + ant-optional, autoconf, automake, - debhelper (>= 7.4.11), + debhelper (>= 8.9.7), default-jdk (>= 1:1.6), default-jdk-doc, help2man, diff --git a/debian/patches/debian/patch-build-system b/debian/patches/debian/patch-build-system index 826ae24..eb1e6a3 100644 --- a/debian/patches/debian/patch-build-system +++ b/debian/patches/debian/patch-build-system @@ -1,7 +1,13 @@ +Description: Patches to upstream build system to disable use of ivy, + use jar files from /usr/share/java and enable the relevant bits of the + test suite for execution during build. +Author: James Page <james.p...@ubuntu.com>, Thomas Koch <tho...@koch.ro> +Forwarded: not-needed + Index: zookeeper/build.xml =================================================================== ---- zookeeper.orig/build.xml 2011-07-12 15:03:47.576170738 +0100 -+++ zookeeper/build.xml 2011-07-12 15:03:55.006170734 +0100 +--- zookeeper.orig/build.xml 2011-10-27 12:56:26.256766856 +0100 ++++ zookeeper/build.xml 2011-10-27 13:34:38.167607772 +0100 @@ -25,7 +25,7 @@ <property environment="env"/> @@ -11,7 +17,7 @@ Index: zookeeper/build.xml <property name="revision.dir" value="${basedir}/.revision" /> <property name="revision.properties" value="revision.properties" /> <property file="${basedir}/src/java/${revision.properties}" /> -@@ -169,21 +169,11 @@ +@@ -169,27 +169,17 @@ <path id="java.classpath"> <pathelement location="${build.classes}"/> <!-- allow the user to override (e.g. if there are local versions) --> @@ -37,6 +43,14 @@ Index: zookeeper/build.xml </path> <path id="test.java.classpath"> + <pathelement location="${test.java.classes}" /> +- <fileset dir="${ivy.test.lib}"> +- <include name="**/*.jar" /> ++ <fileset dir="/usr/share/java"> ++ <include name="junit4.jar" /> + </fileset> + <path refid="java.classpath"/> + </path> @@ -223,7 +213,7 @@ targetfile="${src_generated.dir}/.generated"/> </target> @@ -55,10 +69,51 @@ Index: zookeeper/build.xml <javac srcdir="${java.src.dir}" destdir="${build.classes}" target="${javac.target}" debug="on"> <classpath refid="java.classpath"/> +@@ -334,7 +324,7 @@ + </javac> + </target> + +- <target name="compile-test" depends="ivy-retrieve-test,compile"> ++ <target name="compile-test" depends="compile"> + <mkdir dir="${test.java.classes}"/> + <javac srcdir="${test.src.dir}" destdir="${test.java.classes}" + target="${javac.target}" debug="on"> +@@ -769,21 +759,10 @@ + <target name="test-init" depends="jar,compile-test"> + <delete dir="${test.log.dir}" /> + <delete dir="${test.tmp.dir}" /> +- <delete dir="${test.data.upgrade.dir}" /> +- <delete dir="${test.data.invalid.dir}" /> + <delete dir="${test.data.dir}" /> + <mkdir dir="${test.log.dir}" /> + <mkdir dir="${test.tmp.dir}" /> + <mkdir dir="${test.data.dir}" /> +- <mkdir dir="${test.data.upgrade.dir}" /> +- <mkdir dir="${test.data.invalid.dir}" /> +- <copy todir="${test.data.upgrade.dir}"> +- <fileset dir="${basedir}/src/java/test/data/upgrade"/> +- </copy> +- <copy todir="${test.data.invalid.dir}"> +- <fileset dir="${basedir}/src/java/test/data/invalidsnap"/> +- </copy> +- + </target> + + <condition property="quicktest"> +@@ -836,6 +815,9 @@ + <batchtest todir="${test.log.dir}" if="fulltest"> + <fileset dir="${test.src.dir}"> + <include name="**/*${test.category}Test.java"/> ++ <exclude name="**/test/UpgradeTest.java"/> ++ <exclude name="**/test/InvalidSnapshotTest.java"/> ++ <exclude name="**/VerGenTest.java"/> + </fileset> + </batchtest> + <batchtest todir="${test.log.dir}" if="testcase"> Index: zookeeper/src/contrib/bookkeeper/build.xml =================================================================== ---- zookeeper.orig/src/contrib/bookkeeper/build.xml 2011-07-12 15:03:47.546170738 +0100 -+++ zookeeper/src/contrib/bookkeeper/build.xml 2011-07-12 15:03:55.006170734 +0100 +--- zookeeper.orig/src/contrib/bookkeeper/build.xml 2011-10-27 12:56:26.208766699 +0100 ++++ zookeeper/src/contrib/bookkeeper/build.xml 2011-10-27 12:57:05.000000000 +0100 @@ -34,7 +34,7 @@ <target name="setjarname"> @@ -70,8 +125,8 @@ Index: zookeeper/src/contrib/bookkeeper/build.xml <target name="init" depends="checkMainCompiled, zookeeperbuildcontrib.init"/> Index: zookeeper/src/contrib/build-contrib.xml =================================================================== ---- zookeeper.orig/src/contrib/build-contrib.xml 2011-07-12 15:03:47.526170738 +0100 -+++ zookeeper/src/contrib/build-contrib.xml 2011-07-12 15:03:55.006170734 +0100 +--- zookeeper.orig/src/contrib/build-contrib.xml 2011-10-27 12:56:26.188766632 +0100 ++++ zookeeper/src/contrib/build-contrib.xml 2011-10-27 12:57:05.000000000 +0100 @@ -70,25 +70,14 @@ <path id="classpath"> @@ -131,8 +186,8 @@ Index: zookeeper/src/contrib/build-contrib.xml Index: zookeeper/src/contrib/zooinspector/build.xml =================================================================== ---- zookeeper.orig/src/contrib/zooinspector/build.xml 2011-07-12 15:03:47.556170738 +0100 -+++ zookeeper/src/contrib/zooinspector/build.xml 2011-07-12 15:04:31.996170711 +0100 +--- zookeeper.orig/src/contrib/zooinspector/build.xml 2011-10-27 12:56:26.236766791 +0100 ++++ zookeeper/src/contrib/zooinspector/build.xml 2011-10-27 12:57:05.000000000 +0100 @@ -20,7 +20,7 @@ diff --git a/debian/rules b/debian/rules index dfd401c..13648c3 100755 --- a/debian/rules +++ b/debian/rules @@ -6,7 +6,7 @@ PYVERS := $(shell pyversions -vr) DEB_UPSTREAM_VERSION=$(shell dpkg-parsechangelog | sed -rne 's,^Version: ([^+]+).*,\1,p') %: - dh --with javahelper --with python2 $@ + dh $@ --with javahelper --with python2 override_dh_auto_build: # TODO exclude the fatjar contrib from upstream tarball and include the rest contrib @@ -46,11 +46,19 @@ override_dh_install: dh_install ifeq (,$(findstring nocheck, $(DEB_BUILD_OPTIONS))) -override_dh_auto_test: - # src/c/tests/TestClient.cc:298: Assertion: equality assertion failed [Expected: -101, Actual : -4] - #ant -propertyfile debian/ant.properties -buildfile debian/build-override.xml test-core - #Testsuite runs ~15 min on my machine. Seems too much for the Debian build daemons - #ant -propertyfile debian/ant.properties -buildfile debian/build-override.xml test-core-java +override_dh_auto_test-arch: + # C testing starts/stops zookeeper + # this ensures that all the right classes are found + for jar in jline log4j-1.2 xercesImpl xmlParserAPIs; do \ + ln -sf /usr/share/java/$$jar.jar build/lib/$$jar.jar; \ + done; + # Execute multi-threaded test suite + $(MAKE) -C src/c zktest-mt + cd src/c && ./zktest-mt + +override_dh_auto_test-indep: + # Run core Java test suite against zookeeper + ant -Dversion=$(DEB_UPSTREAM_VERSION) -DlastRevision=-1 -Dtestcase=VerGenTest -d test-core-java endif override_dh_clean: @@ -94,6 +102,7 @@ override_dh_auto_clean: rm -rf src/c/config.sub rm -rf src/c/configure rm -rf src/c/ltmain.sh + rm -rf src/c/TEST-* ifeq (,$(findstring nodocs, $(DEB_BUILD_OPTIONS))) override_dh_installdocs: -- Apache ZooKeeper _______________________________________________ pkg-java-commits mailing list pkg-java-comm...@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-java-commits