[libcommons-lang3-java] 03/03: New upstream release (3.2.1)
Emmanuel Bourg
ebourg-guest at moszumanska.debian.org
Fri Jan 10 11:40:42 UTC 2014
This is an automated email from the git hooks/post-receive script.
ebourg-guest pushed a commit to branch master
in repository libcommons-lang3-java.
commit 625c85f2fb7d3ff1344bf1e6f01d6a0659b938dd
Author: Emmanuel Bourg <ebourg at apache.org>
Date: Fri Jan 10 12:39:46 2014 +0100
New upstream release (3.2.1)
---
debian/changelog | 9 +-
debian/copyright | 4 +-
debian/libcommons-lang3-java.poms | 12 +-
debian/maven.ignoreRules | 2 +
debian/patches/0002-ToStringBuilderTest-jdk7.patch | 663 ---------------------
debian/patches/disable_testGetUserHome_test.diff | 24 +-
debian/patches/series | 1 -
7 files changed, 31 insertions(+), 684 deletions(-)
diff --git a/debian/changelog b/debian/changelog
index 95d6499..9de43af 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,12 +1,17 @@
-libcommons-lang3-java (3.1-3) UNRELEASED; urgency=medium
+libcommons-lang3-java (3.2.1-1) unstable; urgency=medium
+ * New upstream release
+ - Refreshed disable_testGetUserHome_test.diff
+ - Removed 0002-ToStringBuilderTest-jdk7.patch
+ - Ignore the Maven dependencies on maven-scm-publish-plugin
+ and maven-antrun-plugin
* debian/watch: Fixed the mangling of the upstream version
* Use XZ compression for the upstream changelog
* debian/copyright: Updated the Format URI and the upstream contact
* Removed the build dependencies on cobertura and clirr
* debian/rules: Install the upstream changelog
- -- Emmanuel Bourg <ebourg at apache.org> Fri, 10 Jan 2014 10:17:17 +0100
+ -- Emmanuel Bourg <ebourg at apache.org> Fri, 10 Jan 2014 12:39:19 +0100
libcommons-lang3-java (3.1-2) unstable; urgency=medium
diff --git a/debian/copyright b/debian/copyright
index 9b4687b..4155d84 100644
--- a/debian/copyright
+++ b/debian/copyright
@@ -1,10 +1,10 @@
Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
-Upstream-Name: Commons Lang
+Upstream-Name: Apache Commons Lang
Upstream-Contact: Apache Commons Developers <dev at commons.apache.org>
Source: http://commons.apache.org/lang/
Files: *
-Copyright: Copyright 2001-2011 The Apache Software Foundation
+Copyright: 2001-2014, The Apache Software Foundation
License: Apache-2.0
Files: debian/*
diff --git a/debian/libcommons-lang3-java.poms b/debian/libcommons-lang3-java.poms
index 8516e3c..64b1188 100644
--- a/debian/libcommons-lang3-java.poms
+++ b/debian/libcommons-lang3-java.poms
@@ -3,8 +3,8 @@
# <path to pom file> [option]*
# where option can be:
# --ignore: ignore this POM and its artifact if any
-# --ignore-pom: don't install the POM with mh_install or mh_installpoms. To use with POM files that are created
-# temporarily for certain artifacts such as Javadoc jars.
+# --ignore-pom: don't install the POM. To use on POM files that are created
+# temporarily for certain artifacts such as Javadoc jars. [mh_install, mh_installpoms]
# --no-parent: remove the <parent> tag from the POM
# --package=<package>: an alternative package to use when installing this POM
# and its artifact
@@ -13,14 +13,16 @@
# --keep-elements=<elem1,elem2>: a list of XML elements to keep in the POM
# during a clean operation with mh_cleanpom or mh_installpom
# --artifact=<path>: path to the build artifact associated with this POM,
-# it will be installed when using the command mh_install
+# it will be installed when using the command mh_install. [mh_install]
# --java-lib: install the jar into /usr/share/java to comply with Debian
# packaging guidelines
# --usj-name=<name>: name to use when installing the library in /usr/share/java
# --usj-version=<version>: version to use when installing the library in /usr/share/java
# --no-usj-versionless: don't install the versionless link in /usr/share/java
-# --dest-jar=<path>: the destination for the real jar
-# it will be installed with mh_install.
+# --dest-jar=<path>: the destination for the real jar.
+# It will be installed with mh_install. [mh_install]
# --classifier=<classifier>: Optional, the classifier for the jar. Empty by default.
+# --site-xml=<location>: Optional, the location for site.xml if it needs to be installed.
+# Empty by default. [mh_install]
#
pom.xml --no-parent --has-package-version --java-lib
diff --git a/debian/maven.ignoreRules b/debian/maven.ignoreRules
index fc51066..513a4c3 100644
--- a/debian/maven.ignoreRules
+++ b/debian/maven.ignoreRules
@@ -14,10 +14,12 @@
# from the POM
# junit junit jar s/3\\..*/3.x/
+org.apache.maven.plugins maven-antrun-plugin * * * *
org.apache.maven.plugins maven-assembly-plugin * * * *
org.apache.maven.plugins maven-changes-plugin * * * *
org.apache.maven.plugins maven-checkstyle-plugin * * * *
org.apache.maven.plugins maven-pmd-plugin * * * *
+org.apache.maven.plugins maven-scm-publish-plugin * * * *
org.codehaus.mojo clirr-maven-plugin * * * *
org.codehaus.mojo cobertura-maven-plugin * * * *
org.codehaus.mojo findbugs-maven-plugin * * * *
diff --git a/debian/patches/0002-ToStringBuilderTest-jdk7.patch b/debian/patches/0002-ToStringBuilderTest-jdk7.patch
deleted file mode 100644
index 3c6b714..0000000
--- a/debian/patches/0002-ToStringBuilderTest-jdk7.patch
+++ /dev/null
@@ -1,663 +0,0 @@
-Description: address test failure on jdk7
- Updates the ToStringBuilderTest class to a newer upstream revision
-Source: http://svn.apache.org/viewvc/commons/proper/lang/trunk/src/test/java/org/apache/commons/lang3/builder/ToStringBuilderTest.java?revision=1525071&view=co
-
---
-diff --git a/src/test/java/org/apache/commons/lang3/builder/ToStringBuilderTest.java b/src/test/java/org/apache/commons/lang3/builder/ToStringBuilderTest.java
-index 88a19b2..37f943b 100644
---- a/src/test/java/org/apache/commons/lang3/builder/ToStringBuilderTest.java
-+++ b/src/test/java/org/apache/commons/lang3/builder/ToStringBuilderTest.java
-@@ -16,26 +16,38 @@
- */
- package org.apache.commons.lang3.builder;
-
--import static org.junit.Assert.*;
-+import static org.junit.Assert.assertEquals;
-+import static org.junit.Assert.assertNull;
-+import static org.junit.Assert.assertSame;
-+import static org.junit.Assume.assumeFalse;
-
- import java.util.ArrayList;
- import java.util.HashMap;
- import java.util.List;
--
--import org.junit.Test;
-+import java.util.Map;
-
- import org.apache.commons.lang3.SystemUtils;
-+import org.junit.After;
-+import org.junit.Test;
-
- /**
- * Unit tests for {@link org.apache.commons.lang3.builder.ToStringBuilder}.
- *
-- * @version $Id: ToStringBuilderTest.java 1154530 2011-08-06 15:43:07Z joehni $
-+ * @version $Id$
- */
- public class ToStringBuilderTest {
-
- private final Integer base = Integer.valueOf(5);
- private final String baseStr = base.getClass().getName() + "@" + Integer.toHexString(System.identityHashCode(base));
-
-+ /*
-+ * All tests should leave the registry empty.
-+ */
-+ @After
-+ public void after(){
-+ validateNullToStringStyleRegistry();
-+ }
-+
- //-----------------------------------------------------------------------
-
- @Test
-@@ -52,8 +64,8 @@ public class ToStringBuilderTest {
- @Test
- public void testConstructorEx3() {
- assertEquals("<null>", new ToStringBuilder(null, null, null).toString());
-- new ToStringBuilder(this.base, null, null);
-- new ToStringBuilder(this.base, ToStringStyle.DEFAULT_STYLE, null);
-+ new ToStringBuilder(this.base, null, null).toString();
-+ new ToStringBuilder(this.base, ToStringStyle.DEFAULT_STYLE, null).toString();
- }
-
- @Test
-@@ -67,15 +79,9 @@ public class ToStringBuilderTest {
- }
- }
-
-- @Test
-+ @Test(expected=IllegalArgumentException.class)
- public void testSetDefaultEx() {
-- try {
-- ToStringBuilder.setDefaultStyle(null);
--
-- } catch (IllegalArgumentException ex) {
-- return;
-- }
-- fail();
-+ ToStringBuilder.setDefaultStyle(null);
- }
-
- @Test
-@@ -96,7 +102,7 @@ public class ToStringBuilderTest {
- */
- @Test
- public void testReflectionCharacter() {
-- Character c = new Character('A');
-+ final Character c = new Character('A');
- assertEquals(this.toBaseString(c) + "[value=A]", ToStringBuilder.reflectionToString(c));
- }
-
-@@ -117,7 +123,7 @@ public class ToStringBuilderTest {
- * @param o the object to create the string for.
- * @return a String in the Object.toString format.
- */
-- private String toBaseString(Object o) {
-+ private String toBaseString(final Object o) {
- return o.getClass().getName() + "@" + Integer.toHexString(System.identityHashCode(o));
- }
-
-@@ -136,7 +142,7 @@ public class ToStringBuilderTest {
- // Gary Gregory - 2003-03-12 - ggregory at seagullsw.com
- //
-
-- public void assertReflectionArray(String expected, Object actual) {
-+ public void assertReflectionArray(final String expected, final Object actual) {
- if (actual == null) {
- // Until ToStringBuilder supports null objects.
- return;
-@@ -150,91 +156,82 @@ public class ToStringBuilderTest {
- @Test
- public void testReflectionObjectArray() {
- Object[] array = new Object[] { null, base, new int[] { 3, 6 } };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{<null>,5,{3,6}}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionLongArray() {
- long[] array = new long[] { 1, 2, -3, 4 };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{1,2,-3,4}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionIntArray() {
- int[] array = new int[] { 1, 2, -3, 4 };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{1,2,-3,4}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionShortArray() {
- short[] array = new short[] { 1, 2, -3, 4 };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{1,2,-3,4}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionyteArray() {
- byte[] array = new byte[] { 1, 2, -3, 4 };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{1,2,-3,4}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionCharArray() {
- char[] array = new char[] { 'A', '2', '_', 'D' };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{A,2,_,D}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionDoubleArray() {
- double[] array = new double[] { 1.0, 2.9876, -3.00001, 4.3 };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{1.0,2.9876,-3.00001,4.3}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionFloatArray() {
- float[] array = new float[] { 1.0f, 2.9876f, -3.00001f, 4.3f };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{1.0,2.9876,-3.00001,4.3}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionBooleanArray() {
- boolean[] array = new boolean[] { true, false, false };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{true,false,false}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- // Reflection Array Array tests
-@@ -242,113 +239,101 @@ public class ToStringBuilderTest {
- @Test
- public void testReflectionFloatArrayArray() {
- float[][] array = new float[][] { { 1.0f, 2.29686f }, null, { Float.NaN } };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{{1.0,2.29686},<null>,{NaN}}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
-
- @Test
- public void testReflectionLongArrayArray() {
- long[][] array = new long[][] { { 1, 2 }, null, { 5 } };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{{1,2},<null>,{5}}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionIntArrayArray() {
- int[][] array = new int[][] { { 1, 2 }, null, { 5 } };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{{1,2},<null>,{5}}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionhortArrayArray() {
- short[][] array = new short[][] { { 1, 2 }, null, { 5 } };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{{1,2},<null>,{5}}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionByteArrayArray() {
- byte[][] array = new byte[][] { { 1, 2 }, null, { 5 } };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{{1,2},<null>,{5}}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionCharArrayArray() {
- char[][] array = new char[][] { { 'A', 'B' }, null, { 'p' } };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{{A,B},<null>,{p}}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionDoubleArrayArray() {
- double[][] array = new double[][] { { 1.0, 2.29686 }, null, { Double.NaN } };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{{1.0,2.29686},<null>,{NaN}}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionBooleanArrayArray() {
- boolean[][] array = new boolean[][] { { true, false }, null, { false } };
-- String baseStr = this.toBaseString(array);
-+ final String baseStr = this.toBaseString(array);
- assertEquals(baseStr + "[{{true,false},<null>,{false}}]", ToStringBuilder.reflectionToString(array));
- assertEquals(baseStr + "[{{true,false},<null>,{false}}]", ToStringBuilder.reflectionToString(array));
- array = null;
- assertReflectionArray("<null>", array);
-- this.validateNullToStringStyleRegistry();
- }
-
- // Reflection hierarchy tests
- @Test
- public void testReflectionHierarchyArrayList() {
-- List<Object> base = new ArrayList<Object>();
-- String baseStr = this.toBaseString(base);
- // note, the test data depends on the internal representation of the ArrayList, which may differ between JDK versions and vendors
-- String expectedWithTransients = baseStr + "[elementData={<null>,<null>,<null>,<null>,<null>,<null>,<null>,<null>,<null>,<null>},size=0,modCount=0]";
-- String toStringWithTransients = ToStringBuilder.reflectionToString(base, null, true);
-+ // representation different for IBM JDK 1.6.0, LANG-727
-+ assumeFalse("IBM Corporation".equals(SystemUtils.JAVA_VENDOR) && "1.6".equals(SystemUtils.JAVA_SPECIFICATION_VERSION));
-+ assumeFalse("Oracle Corporation".equals(SystemUtils.JAVA_VENDOR) && "1.6".compareTo(SystemUtils.JAVA_SPECIFICATION_VERSION) < 0);
-+ final List<Object> base = new ArrayList<Object>();
-+ final String baseStr = this.toBaseString(base);
-+ final String expectedWithTransients = baseStr + "[elementData={<null>,<null>,<null>,<null>,<null>,<null>,<null>,<null>,<null>,<null>},size=0,modCount=0]";
-+ final String toStringWithTransients = ToStringBuilder.reflectionToString(base, null, true);
- if (!expectedWithTransients.equals(toStringWithTransients)) {
-- // representation different for IBM JDK 1.6.0, LANG-727
-- if (!("IBM Corporation".equals(SystemUtils.JAVA_VENDOR) && "1.6".equals(SystemUtils.JAVA_SPECIFICATION_VERSION))) {
-- assertEquals(expectedWithTransients, toStringWithTransients);
-- }
-+ assertEquals(expectedWithTransients, toStringWithTransients);
- }
-- String expectedWithoutTransients = baseStr + "[size=0]";
-- String toStringWithoutTransients = ToStringBuilder.reflectionToString(base, null, false);
-+ final String expectedWithoutTransients = baseStr + "[size=0]";
-+ final String toStringWithoutTransients = ToStringBuilder.reflectionToString(base, null, false);
- if (!expectedWithoutTransients.equals(toStringWithoutTransients)) {
-- // representation different for IBM JDK 1.6.0, LANG-727
-- if (!("IBM Corporation".equals(SystemUtils.JAVA_VENDOR) && "1.6".equals(SystemUtils.JAVA_SPECIFICATION_VERSION))) {
-- assertEquals(expectedWithoutTransients, toStringWithoutTransients);
-- }
-+ assertEquals(expectedWithoutTransients, toStringWithoutTransients);
- }
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionHierarchy() {
-- ReflectionTestFixtureA baseA = new ReflectionTestFixtureA();
-+ final ReflectionTestFixtureA baseA = new ReflectionTestFixtureA();
- String baseStr = this.toBaseString(baseA);
- assertEquals(baseStr + "[a=a]", ToStringBuilder.reflectionToString(baseA));
- assertEquals(baseStr + "[a=a]", ToStringBuilder.reflectionToString(baseA, null));
-@@ -358,7 +343,7 @@ public class ToStringBuilderTest {
- assertEquals(baseStr + "[a=a]", ToStringBuilder.reflectionToString(baseA, null, false, Object.class));
- assertEquals(baseStr + "[a=a]", ToStringBuilder.reflectionToString(baseA, null, false, ReflectionTestFixtureA.class));
-
-- ReflectionTestFixtureB baseB = new ReflectionTestFixtureB();
-+ final ReflectionTestFixtureB baseB = new ReflectionTestFixtureB();
- baseStr = this.toBaseString(baseB);
- assertEquals(baseStr + "[b=b,a=a]", ToStringBuilder.reflectionToString(baseB));
- assertEquals(baseStr + "[b=b,a=a]", ToStringBuilder.reflectionToString(baseB));
-@@ -369,26 +354,25 @@ public class ToStringBuilderTest {
- assertEquals(baseStr + "[b=b,a=a]", ToStringBuilder.reflectionToString(baseB, null, false, Object.class));
- assertEquals(baseStr + "[b=b,a=a]", ToStringBuilder.reflectionToString(baseB, null, false, ReflectionTestFixtureA.class));
- assertEquals(baseStr + "[b=b]", ToStringBuilder.reflectionToString(baseB, null, false, ReflectionTestFixtureB.class));
-- this.validateNullToStringStyleRegistry();
- }
-
- static class ReflectionTestFixtureA {
- @SuppressWarnings("unused")
-- private char a='a';
-+ private final char a='a';
- @SuppressWarnings("unused")
- private transient char transientA='t';
- }
-
- static class ReflectionTestFixtureB extends ReflectionTestFixtureA {
- @SuppressWarnings("unused")
-- private char b='b';
-+ private final char b='b';
- @SuppressWarnings("unused")
- private transient char transientB='t';
- }
-
- @Test
- public void testInnerClassReflection() {
-- Outer outer = new Outer();
-+ final Outer outer = new Outer();
- assertEquals(toBaseString(outer) + "[inner=" + toBaseString(outer.inner) + "[]]", outer.toString());
- }
-
-@@ -413,12 +397,11 @@ public class ToStringBuilderTest {
- */
- @Test
- public void testReflectionArrayCycle() throws Exception {
-- Object[] objects = new Object[1];
-+ final Object[] objects = new Object[1];
- objects[0] = objects;
- assertEquals(
- this.toBaseString(objects) + "[{" + this.toBaseString(objects) + "}]",
- ToStringBuilder.reflectionToString(objects));
-- this.validateNullToStringStyleRegistry();
- }
-
- /**
-@@ -426,8 +409,8 @@ public class ToStringBuilderTest {
- */
- @Test
- public void testReflectionArrayCycleLevel2() throws Exception {
-- Object[] objects = new Object[1];
-- Object[] objectsLevel2 = new Object[1];
-+ final Object[] objects = new Object[1];
-+ final Object[] objectsLevel2 = new Object[1];
- objects[0] = objectsLevel2;
- objectsLevel2[0] = objects;
- assertEquals(
-@@ -436,17 +419,16 @@ public class ToStringBuilderTest {
- assertEquals(
- this.toBaseString(objectsLevel2) + "[{{" + this.toBaseString(objectsLevel2) + "}}]",
- ToStringBuilder.reflectionToString(objectsLevel2));
-- this.validateNullToStringStyleRegistry();
- }
-
- @Test
- public void testReflectionArrayArrayCycle() throws Exception {
-- Object[][] objects = new Object[2][2];
-+ final Object[][] objects = new Object[2][2];
- objects[0][0] = objects;
- objects[0][1] = objects;
- objects[1][0] = objects;
- objects[1][1] = objects;
-- String basicToString = this.toBaseString(objects);
-+ final String basicToString = this.toBaseString(objects);
- assertEquals(
- basicToString
- + "[{{"
-@@ -459,7 +441,6 @@ public class ToStringBuilderTest {
- + basicToString
- + "}}]",
- ToStringBuilder.reflectionToString(objects));
-- this.validateNullToStringStyleRegistry();
- }
-
- /**
-@@ -495,7 +476,7 @@ public class ToStringBuilderTest {
- public SimpleReflectionTestFixture() {
- }
-
-- public SimpleReflectionTestFixture(Object o) {
-+ public SimpleReflectionTestFixture(final Object o) {
- this.o = o;
- }
-
-@@ -507,7 +488,7 @@ public class ToStringBuilderTest {
-
- private static class SelfInstanceVarReflectionTestFixture {
- @SuppressWarnings("unused")
-- private SelfInstanceVarReflectionTestFixture typeIsSelf;
-+ private final SelfInstanceVarReflectionTestFixture typeIsSelf;
-
- public SelfInstanceVarReflectionTestFixture() {
- this.typeIsSelf = this;
-@@ -521,8 +502,8 @@ public class ToStringBuilderTest {
-
- private static class SelfInstanceTwoVarsReflectionTestFixture {
- @SuppressWarnings("unused")
-- private SelfInstanceTwoVarsReflectionTestFixture typeIsSelf;
-- private String otherType = "The Other Type";
-+ private final SelfInstanceTwoVarsReflectionTestFixture typeIsSelf;
-+ private final String otherType = "The Other Type";
-
- public SelfInstanceTwoVarsReflectionTestFixture() {
- this.typeIsSelf = this;
-@@ -546,10 +527,9 @@ public class ToStringBuilderTest {
- */
- @Test
- public void testSimpleReflectionObjectCycle() throws Exception {
-- SimpleReflectionTestFixture simple = new SimpleReflectionTestFixture();
-+ final SimpleReflectionTestFixture simple = new SimpleReflectionTestFixture();
- simple.o = simple;
- assertEquals(this.toBaseString(simple) + "[o=" + this.toBaseString(simple) + "]", simple.toString());
-- this.validateNullToStringStyleRegistry();
- }
-
- /**
-@@ -559,9 +539,8 @@ public class ToStringBuilderTest {
- */
- @Test
- public void testSelfInstanceVarReflectionObjectCycle() throws Exception {
-- SelfInstanceVarReflectionTestFixture test = new SelfInstanceVarReflectionTestFixture();
-+ final SelfInstanceVarReflectionTestFixture test = new SelfInstanceVarReflectionTestFixture();
- assertEquals(this.toBaseString(test) + "[typeIsSelf=" + this.toBaseString(test) + "]", test.toString());
-- this.validateNullToStringStyleRegistry();
- }
-
- /**
-@@ -572,9 +551,8 @@ public class ToStringBuilderTest {
- */
- @Test
- public void testSelfInstanceTwoVarsReflectionObjectCycle() throws Exception {
-- SelfInstanceTwoVarsReflectionTestFixture test = new SelfInstanceTwoVarsReflectionTestFixture();
-+ final SelfInstanceTwoVarsReflectionTestFixture test = new SelfInstanceTwoVarsReflectionTestFixture();
- assertEquals(this.toBaseString(test) + "[typeIsSelf=" + this.toBaseString(test) + ",otherType=" + test.getOtherType().toString() + "]", test.toString());
-- this.validateNullToStringStyleRegistry();
- }
-
-
-@@ -585,14 +563,13 @@ public class ToStringBuilderTest {
- */
- @Test
- public void testReflectionObjectCycle() throws Exception {
-- ReflectionTestCycleA a = new ReflectionTestCycleA();
-- ReflectionTestCycleB b = new ReflectionTestCycleB();
-+ final ReflectionTestCycleA a = new ReflectionTestCycleA();
-+ final ReflectionTestCycleB b = new ReflectionTestCycleB();
- a.b = b;
- b.a = a;
- assertEquals(
- this.toBaseString(a) + "[b=" + this.toBaseString(b) + "[a=" + this.toBaseString(a) + "]]",
- a.toString());
-- this.validateNullToStringStyleRegistry();
- }
-
- /**
-@@ -603,8 +580,8 @@ public class ToStringBuilderTest {
- */
- @Test
- public void testReflectionArrayAndObjectCycle() throws Exception {
-- Object[] objects = new Object[1];
-- SimpleReflectionTestFixture simple = new SimpleReflectionTestFixture(objects);
-+ final Object[] objects = new Object[1];
-+ final SimpleReflectionTestFixture simple = new SimpleReflectionTestFixture(objects);
- objects[0] = simple;
- assertEquals(
- this.toBaseString(objects)
-@@ -621,15 +598,11 @@ public class ToStringBuilderTest {
- + this.toBaseString(simple)
- + "}]",
- ToStringBuilder.reflectionToString(simple));
-- this.validateNullToStringStyleRegistry();
- }
-
- void validateNullToStringStyleRegistry() {
-- if (ToStringStyle.getRegistry() != null) {
-- System.out.println(ToStringStyle.getRegistry());
-- }
--
-- assertNull(ToStringStyle.getRegistry());
-+ final Map<Object, Object> registry = ToStringStyle.getRegistry();
-+ assertNull("Expected null, actual: "+registry, registry);
- }
- // End: Reflection cycle tests
-
-@@ -655,8 +628,8 @@ public class ToStringBuilderTest {
-
- @Test
- public void testObject() {
-- Integer i3 = Integer.valueOf(3);
-- Integer i4 = Integer.valueOf(4);
-+ final Integer i3 = Integer.valueOf(3);
-+ final Integer i4 = Integer.valueOf(4);
- assertEquals(baseStr + "[<null>]", new ToStringBuilder(base).append((Object) null).toString());
- assertEquals(baseStr + "[3]", new ToStringBuilder(base).append(i3).toString());
- assertEquals(baseStr + "[a=<null>]", new ToStringBuilder(base).append("a", (Object) null).toString());
-@@ -673,8 +646,8 @@ public class ToStringBuilderTest {
-
- @Test
- public void testObjectBuild() {
-- Integer i3 = Integer.valueOf(3);
-- Integer i4 = Integer.valueOf(4);
-+ final Integer i3 = Integer.valueOf(3);
-+ final Integer i4 = Integer.valueOf(4);
- assertEquals(baseStr + "[<null>]", new ToStringBuilder(base).append((Object) null).build());
- assertEquals(baseStr + "[3]", new ToStringBuilder(base).append(i3).build());
- assertEquals(baseStr + "[a=<null>]", new ToStringBuilder(base).append("a", (Object) null).build());
-@@ -920,14 +893,13 @@ public class ToStringBuilderTest {
-
- @Test
- public void testObjectCycle() {
-- ObjectCycle a = new ObjectCycle();
-- ObjectCycle b = new ObjectCycle();
-+ final ObjectCycle a = new ObjectCycle();
-+ final ObjectCycle b = new ObjectCycle();
- a.obj = b;
- b.obj = a;
-
-- String expected = toBaseString(a) + "[" + toBaseString(b) + "[" + toBaseString(a) + "]]";
-+ final String expected = toBaseString(a) + "[" + toBaseString(b) + "[" + toBaseString(a) + "]]";
- assertEquals(expected, a.toString());
-- validateNullToStringStyleRegistry();
- }
-
- static class ObjectCycle {
-@@ -941,7 +913,7 @@ public class ToStringBuilderTest {
-
- @Test
- public void testSimpleReflectionStatics() {
-- SimpleReflectionStaticFieldsFixture instance1 = new SimpleReflectionStaticFieldsFixture();
-+ final SimpleReflectionStaticFieldsFixture instance1 = new SimpleReflectionStaticFieldsFixture();
- assertEquals(
- this.toBaseString(instance1) + "[staticString=staticString,staticInt=12345]",
- ReflectionToStringBuilder.toString(instance1, null, false, true, SimpleReflectionStaticFieldsFixture.class));
-@@ -961,7 +933,7 @@ public class ToStringBuilderTest {
- */
- @Test
- public void testReflectionStatics() {
-- ReflectionStaticFieldsFixture instance1 = new ReflectionStaticFieldsFixture();
-+ final ReflectionStaticFieldsFixture instance1 = new ReflectionStaticFieldsFixture();
- assertEquals(
- this.toBaseString(instance1) + "[staticString=staticString,staticInt=12345,instanceString=instanceString,instanceInt=67890]",
- ReflectionToStringBuilder.toString(instance1, null, false, true, ReflectionStaticFieldsFixture.class));
-@@ -981,7 +953,7 @@ public class ToStringBuilderTest {
- */
- @Test
- public void testInheritedReflectionStatics() {
-- InheritedReflectionStaticFieldsFixture instance1 = new InheritedReflectionStaticFieldsFixture();
-+ final InheritedReflectionStaticFieldsFixture instance1 = new InheritedReflectionStaticFieldsFixture();
- assertEquals(
- this.toBaseString(instance1) + "[staticString2=staticString2,staticInt2=67890]",
- ReflectionToStringBuilder.toString(instance1, null, false, true, InheritedReflectionStaticFieldsFixture.class));
-@@ -1021,7 +993,7 @@ public class ToStringBuilderTest {
- * @return the String result
- * @throws IllegalArgumentException if the Object is <code>null</code>
- */
-- public <T> String toStringWithStatics(T object, ToStringStyle style, Class<? super T> reflectUpToClass) {
-+ public <T> String toStringWithStatics(final T object, final ToStringStyle style, final Class<? super T> reflectUpToClass) {
- return ReflectionToStringBuilder.toString(object, style, false, true, reflectUpToClass);
- }
-
-@@ -1030,23 +1002,23 @@ public class ToStringBuilderTest {
- */
- @Test
- public void test_setUpToClass_valid() {
-- Integer val = Integer.valueOf(5);
-- ReflectionToStringBuilder test = new ReflectionToStringBuilder(val);
-+ final Integer val = Integer.valueOf(5);
-+ final ReflectionToStringBuilder test = new ReflectionToStringBuilder(val);
- test.setUpToClass(Number.class);
-+ test.toString();
- }
-
- /**
- * Tests ReflectionToStringBuilder setUpToClass().
- */
-- @Test
-+ @Test(expected=IllegalArgumentException.class)
- public void test_setUpToClass_invalid() {
-- Integer val = Integer.valueOf(5);
-- ReflectionToStringBuilder test = new ReflectionToStringBuilder(val);
-+ final Integer val = Integer.valueOf(5);
-+ final ReflectionToStringBuilder test = new ReflectionToStringBuilder(val);
- try {
- test.setUpToClass(String.class);
-- fail();
-- } catch (IllegalArgumentException ex) {
-- // expected
-+ } finally {
-+ test.toString();
- }
- }
-
-@@ -1099,8 +1071,8 @@ public class ToStringBuilderTest {
-
- @Test
- public void testAppendToStringUsingMultiLineStyle() {
-- MultiLineTestObject obj = new MultiLineTestObject();
-- ToStringBuilder testBuilder = new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
-+ final MultiLineTestObject obj = new MultiLineTestObject();
-+ final ToStringBuilder testBuilder = new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
- .appendToString(obj.toString());
- assertEquals(testBuilder.toString().indexOf("testInt=31337"), -1);
- }
diff --git a/debian/patches/disable_testGetUserHome_test.diff b/debian/patches/disable_testGetUserHome_test.diff
index ebed752..10b8681 100644
--- a/debian/patches/disable_testGetUserHome_test.diff
+++ b/debian/patches/disable_testGetUserHome_test.diff
@@ -5,17 +5,19 @@ Last-Update: 2012-05-27
Forwarded: not-needed
--- a/src/test/java/org/apache/commons/lang3/SystemUtilsTest.java
+++ b/src/test/java/org/apache/commons/lang3/SystemUtilsTest.java
-@@ -81,11 +81,11 @@
- /**
+@@ -20,6 +20,7 @@
+ package org.apache.commons.lang3;
+
+ import org.junit.Test;
++import org.junit.Ignore;
+ import static org.junit.Assert.*;
+ import static org.apache.commons.lang3.JavaVersion.JAVA_1_4;
+
+@@ -83,6 +84,7 @@
* Assums no security manager exists.
*/
-- public void testGetUserHome() {
-+ /*public void testGetUserHome() {
- File dir = SystemUtils.getUserHome();
+ @Test
++ @Ignore
+ public void testGetUserHome() {
+ final File dir = SystemUtils.getUserHome();
Assert.assertNotNull(dir);
- Assert.assertTrue(dir.exists());
-- }
-+ }*/
-
- public void testIS_JAVA() {
- String javaVersion = System.getProperty("java.version");
diff --git a/debian/patches/series b/debian/patches/series
index 8e3c931..1e4781e 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,2 +1 @@
disable_testGetUserHome_test.diff
-0002-ToStringBuilderTest-jdk7.patch
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/libcommons-lang3-java.git
More information about the pkg-java-commits
mailing list