Author: ssteiner
Date: Fri Sep 23 10:15:44 2022
New Revision: 1904229

URL: http://svn.apache.org/viewvc?rev=1904229&view=rev
Log:
Fix tests on Java 19

Modified:
    
xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/render/pdf/ImageRenderedAdapterTestCase.java
    
xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/svg/font/BasicGlyphVectorTestCase.java
    xmlgraphics/fop/trunk/fop/build.xml
    xmlgraphics/fop/trunk/pom.xml

Modified: 
xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/render/pdf/ImageRenderedAdapterTestCase.java
URL: 
http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/render/pdf/ImageRenderedAdapterTestCase.java?rev=1904229&r1=1904228&r2=1904229&view=diff
==============================================================================
--- 
xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/render/pdf/ImageRenderedAdapterTestCase.java
 (original)
+++ 
xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/render/pdf/ImageRenderedAdapterTestCase.java
 Fri Sep 23 10:15:44 2022
@@ -20,6 +20,7 @@
 package org.apache.fop.render.pdf;
 
 import java.awt.Color;
+import java.awt.color.ColorSpace;
 import java.awt.color.ICC_Profile;
 import java.awt.image.BufferedImage;
 import java.awt.image.IndexColorModel;
@@ -181,8 +182,7 @@ public class ImageRenderedAdapterTestCas
         // ICC Color info
         PDFFactory factory = mock(PDFFactory.class);
         PDFICCStream iccStream = mock(PDFICCStream.class);
-        ICC_Profile iccProfile = mock(ICC_Profile.class);
-        when(iccProfile.getNumComponents()).thenReturn(4);
+        ICC_Profile iccProfile = ICC_Profile.getInstance(ColorSpace.CS_sRGB);
         when(iccStream.getICCProfile()).thenReturn(iccProfile);
         when(factory.makePDFICCStream()).thenReturn(iccStream);
         PDFICCBasedColorSpace iccbcs = new PDFICCBasedColorSpace(null, 
iccStream);

Modified: 
xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/svg/font/BasicGlyphVectorTestCase.java
URL: 
http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/svg/font/BasicGlyphVectorTestCase.java?rev=1904229&r1=1904228&r2=1904229&view=diff
==============================================================================
--- 
xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/svg/font/BasicGlyphVectorTestCase.java
 (original)
+++ 
xmlgraphics/fop/trunk/fop-core/src/test/java/org/apache/fop/svg/font/BasicGlyphVectorTestCase.java
 Fri Sep 23 10:15:44 2022
@@ -168,7 +168,10 @@ public class BasicGlyphVectorTestCase ex
         for (int i = 0; i < 3; i++) {
             glyphVector.setGlyphTransform(i, new AffineTransform(0.7, 0.7, 
-0.7, 0.7, 0, 0));
         }
-        assertEquals(new Rectangle2D.Float(-2.8f, -5.6f, 37.8f, 16.8f), 
glyphVector.getLogicalBounds());
+        Rectangle2D bounds = glyphVector.getLogicalBounds();
+        assertEquals(new Rectangle2D.Float(-2.8f, -5.6f, 37.8f, 16.8f),
+                new Rectangle2D.Float((float) bounds.getX(), (float) 
bounds.getY(),
+                        (float) bounds.getWidth(), (float) 
bounds.getHeight()));
     }
 
     @Test

Modified: xmlgraphics/fop/trunk/fop/build.xml
URL: 
http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/fop/build.xml?rev=1904229&r1=1904228&r2=1904229&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/fop/build.xml (original)
+++ xmlgraphics/fop/trunk/fop/build.xml Fri Sep 23 10:15:44 2022
@@ -159,8 +159,8 @@ list of possible build targets.
   <property name="javac.debug" value="on"/>
   <property name="javac.optimize" value="off"/>
   <property name="javac.deprecation" value="on"/>
-  <property name="javac.source" value="1.7"/>
-  <property name="javac.target" value="1.7"/>
+  <property name="javac.source" value="1.8"/>
+  <property name="javac.target" value="1.8"/>
   <property name="javac.fork" value="no"/>
   <property name="junit.fork" value="yes"/>
   <property name="junit.haltonfailure" value="off"/>

Modified: xmlgraphics/fop/trunk/pom.xml
URL: 
http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/pom.xml?rev=1904229&r1=1904228&r2=1904229&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/pom.xml (original)
+++ xmlgraphics/fop/trunk/pom.xml Fri Sep 23 10:15:44 2022
@@ -13,7 +13,7 @@
   <properties>
     <ant.version>1.9.15</ant.version>
     <antrun.plugin.version>1.8</antrun.plugin.version>
-    <batik.version>1.14.0-SNAPSHOT</batik.version>
+    <batik.version>1.15.0-SNAPSHOT</batik.version>
     <build.helper.plugin.version>1.9.1</build.helper.plugin.version>
     <checkstyle.plugin.version>2.14</checkstyle.plugin.version>
     <commons.io.version>2.11.0</commons.io.version>
@@ -22,7 +22,7 @@
     <exec.plugin.version>1.4.0</exec.plugin.version>
     <findbugs.plugin.version>3.0.4</findbugs.plugin.version>
     <jar.plugin.version>3.1.1</jar.plugin.version>
-    <java.version>1.7</java.version>
+    <java.version>1.8</java.version>
     <junit.version>4.11</junit.version>
     <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
     
<project.info.reports.plugin.version>2.8</project.info.reports.plugin.version>



---------------------------------------------------------------------
To unsubscribe, e-mail: fop-commits-unsubscr...@xmlgraphics.apache.org
For additional commands, e-mail: fop-commits-h...@xmlgraphics.apache.org

Reply via email to