[xsom] 01/01: Added a patch to replace the XML schema used by the tests
Emmanuel Bourg
ebourg-guest at moszumanska.debian.org
Tue Dec 17 15:04:23 UTC 2013
This is an automated email from the git hooks/post-receive script.
ebourg-guest pushed a commit to branch master
in repository xsom.
commit 3992475a5d4b754148c71e46f669fe89a238a6f0
Author: Emmanuel Bourg <ebourg at apache.org>
Date: Tue Dec 17 15:51:13 2013 +0100
Added a patch to replace the XML schema used by the tests
---
debian/patches/02-use-local-schemas.patch | 23 +++++++++++++++++++++++
debian/patches/series | 1 +
debian/rules | 15 ---------------
3 files changed, 24 insertions(+), 15 deletions(-)
diff --git a/debian/patches/02-use-local-schemas.patch b/debian/patches/02-use-local-schemas.patch
new file mode 100644
index 0000000..b768584
--- /dev/null
+++ b/debian/patches/02-use-local-schemas.patch
@@ -0,0 +1,23 @@
+Description: Use a local XML schema to avoid fetching an external resource from the network during the build
+Author: Emmanuel Bourg <ebourg at apache.org>
+Forwarded: not-needed
+--- a/test/XSOMParserTest.java
++++ b/test/XSOMParserTest.java
+@@ -60,7 +60,7 @@
+ */
+ public class XSOMParserTest extends TestCase {
+
+- private static String docURLStr = "http://docs.oasis-open.org/regrep/v3.0/schema/lcm.xsd";
++ private static String docURLStr = "debian/local/lcm.xsd";
+ //private static String docURLStr = "http://ebxmlrr.sourceforge.net/private/sun/irs/ContactMechanism/IRS-ContactMechanismCommonAggregateComponents-1.0.xsd";
+ private static URL docURL = null;
+ private static XSOMParser instance = null;
+@@ -71,7 +71,7 @@
+
+ protected void setUp() throws Exception {
+ if (docURL == null) {
+- docURL = new URL(docURLStr);
++ docURL = new java.io.File(docURLStr).toURI().toURL();
+
+ instance = new XSOMParser();
+ }
diff --git a/debian/patches/series b/debian/patches/series
index e9dcb24..56e6b54 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1,2 @@
01-mangle-jars.diff
+02-use-local-schemas.patch
diff --git a/debian/rules b/debian/rules
index 4b5b85d..d8ef6a9 100755
--- a/debian/rules
+++ b/debian/rules
@@ -5,24 +5,9 @@ JAVA_HOME := /usr/lib/jvm/default-java
%:
dh $@ --buildsystem=maven
-override_dh_auto_build:
- # Replace the URL of the XSD file used by the tests with its
- # absolute filesystem location:
- sed -i \
- 's|http://docs.oasis-open.org/regrep/v3.0/schema/lcm.xsd|file://$(CURDIR)/debian/local/lcm.xsd|' \
- test/XSOMParserTest.java
-
- dh_auto_build
-
-
override_dh_auto_clean:
- sed -i \
- 's|file://$(CURDIR)/debian/local/lcm.xsd|http://docs.oasis-open.org/regrep/v3.0/schema/lcm.xsd|' \
- test/XSOMParserTest.java
rm -Rf build
-
dh_auto_clean
-
get-orig-source:
uscan --download-version $(DEB_UPSTREAM_VERSION) --force-download --rename
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/xsom.git
More information about the pkg-java-commits
mailing list