You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pdfbox.apache.org by ti...@apache.org on 2014/07/11 22:49:03 UTC
svn commit: r1609832 -
/pdfbox/trunk/pdfbox/src/test/java/org/apache/pdfbox/pdmodel/common/TestPDNumberTreeNode.java
Author: tilman
Date: Fri Jul 11 20:49:02 2014
New Revision: 1609832
URL: http://svn.apache.org/r1609832
Log:
PDFBOX-2147: fix problem with last commit (boxing / unboxing)
Modified:
pdfbox/trunk/pdfbox/src/test/java/org/apache/pdfbox/pdmodel/common/TestPDNumberTreeNode.java
Modified: pdfbox/trunk/pdfbox/src/test/java/org/apache/pdfbox/pdmodel/common/TestPDNumberTreeNode.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/pdfbox/src/test/java/org/apache/pdfbox/pdmodel/common/TestPDNumberTreeNode.java?rev=1609832&r1=1609831&r2=1609832&view=diff
==============================================================================
--- pdfbox/trunk/pdfbox/src/test/java/org/apache/pdfbox/pdmodel/common/TestPDNumberTreeNode.java (original)
+++ pdfbox/trunk/pdfbox/src/test/java/org/apache/pdfbox/pdmodel/common/TestPDNumberTreeNode.java Fri Jul 11 20:49:02 2014
@@ -42,7 +42,7 @@ public class TestPDNumberTreeNode extend
private PDNumberTreeNode node24;
public static class PDTest implements COSObjectable {
- private int value;
+ private final int value;
public PDTest(int value) {
this.value = value;
@@ -52,6 +52,7 @@ public class TestPDNumberTreeNode extend
this.value = cosInt.intValue();
}
+ @Override
public COSBase getCOSObject()
{
return COSInteger.get( value );
@@ -143,13 +144,13 @@ public class TestPDNumberTreeNode extend
public void testUpperLimit() throws IOException
{
- Assert.assertEquals(7, this.node5.getUpperLimit());
- Assert.assertEquals(7, this.node2.getUpperLimit());
+ Assert.assertEquals(7, (int) this.node5.getUpperLimit());
+ Assert.assertEquals(7, (int) this.node2.getUpperLimit());
- Assert.assertEquals(12, this.node24.getUpperLimit());
- Assert.assertEquals(12, this.node4.getUpperLimit());
+ Assert.assertEquals(12, (int) this.node24.getUpperLimit());
+ Assert.assertEquals(12, (int) this.node4.getUpperLimit());
- Assert.assertEquals(12, this.node1.getUpperLimit());
+ Assert.assertEquals(12, (int) this.node1.getUpperLimit());
this.node24.setNumbers( new HashMap<Integer, COSObjectable>() );
Assert.assertNull( this.node24.getUpperLimit() );
@@ -163,13 +164,13 @@ public class TestPDNumberTreeNode extend
public void testLowerLimit() throws IOException
{
- Assert.assertEquals(1, this.node5.getLowerLimit());
- Assert.assertEquals(1, this.node2.getLowerLimit());
+ Assert.assertEquals(1, (int) this.node5.getLowerLimit());
+ Assert.assertEquals(1, (int) this.node2.getLowerLimit());
- Assert.assertEquals(8, this.node24.getLowerLimit());
- Assert.assertEquals(8, this.node4.getLowerLimit());
+ Assert.assertEquals(8, (int) this.node24.getLowerLimit());
+ Assert.assertEquals(8, (int) this.node4.getLowerLimit());
- Assert.assertEquals(1, this.node1.getLowerLimit());
+ Assert.assertEquals(1, (int) this.node1.getLowerLimit());
this.node24.setNumbers( new HashMap<Integer, COSObjectable>() );
Assert.assertNull( this.node24.getLowerLimit() );