[dynalang] 06/07: Fixed a test failure with Java 8

Emmanuel Bourg ebourg-guest at moszumanska.debian.org
Tue May 13 08:19:36 UTC 2014


This is an automated email from the git hooks/post-receive script.

ebourg-guest pushed a commit to branch master
in repository dynalang.

commit 012a8f5904c42784433f8e6a065ff0e72293469d
Author: Emmanuel Bourg <ebourg at apache.org>
Date:   Tue May 13 10:08:23 2014 +0200

    Fixed a test failure with Java 8
---
 debian/changelog                              |  1 +
 debian/patches/0003-java8-compatibility.patch | 19 +++++++++++++++++++
 debian/patches/series                         |  1 +
 3 files changed, 21 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index f3153a7..f1f54e3 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,6 +1,7 @@
 dynalang (0.4-2) UNRELEASED; urgency=medium
 
   * Team upload.
+  * Fixed a test failure with Java 8
   * debian/control:
     - Use canonical URLs for the Vcs-* fields
     - Standards-Version updated to 3.9.5 (no changes)
diff --git a/debian/patches/0003-java8-compatibility.patch b/debian/patches/0003-java8-compatibility.patch
new file mode 100644
index 0000000..3a3c16d
--- /dev/null
+++ b/debian/patches/0003-java8-compatibility.patch
@@ -0,0 +1,19 @@
+Description: Fixes a test failure caused by the new methods added to the Map interface in Java 8
+Author: Emmanuel Bourg <ebourg at apache.org>
+Forwarded: no
+--- a/mop/testsrc/org/dynalang/mop/impl/test/TestStandardMetaobjectProtocolFactory.java
++++ b/mop/testsrc/org/dynalang/mop/impl/test/TestStandardMetaobjectProtocolFactory.java
+@@ -219,6 +219,11 @@
+ 	while(it.hasNext()) {
+ 	    s2.add(it.next());
+ 	}
++	// Ignore the new Java 8 methods
++	String[] java8methods = new String[] {"compute", "computeIfAbsent", "computeIfPresent", "forEach", "getOrDefault", "merge", "putIfAbsent", "replace", "replaceAll"};
++	for (String ignoredMethod : java8methods) {
++	    s2.remove(ignoredMethod);
++	}
+ 	assertEquals(s1, s2);
+     }
+-}
+\ No newline at end of file
++}
diff --git a/debian/patches/series b/debian/patches/series
index 27d3769..5ccb13f 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,2 +1,3 @@
 0001-disable-ivy.patch
 0002-fix-build-failure.patch
+0003-java8-compatibility.patch

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/dynalang.git



More information about the pkg-java-commits mailing list