commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r995614 - in /commons/proper/sanselan/trunk/src/test/java/org/apache/sanselan/formats/png: PngTextTest.java PngWriteReadTest.java
Date Fri, 10 Sep 2010 00:34:03 GMT
Author: sebb
Date: Fri Sep 10 00:34:02 2010
New Revision: 995614

URL: http://svn.apache.org/viewvc?rev=995614&view=rev
Log:
Avoid Eclipse NPE warnings

Modified:
    commons/proper/sanselan/trunk/src/test/java/org/apache/sanselan/formats/png/PngTextTest.java
    commons/proper/sanselan/trunk/src/test/java/org/apache/sanselan/formats/png/PngWriteReadTest.java

Modified: commons/proper/sanselan/trunk/src/test/java/org/apache/sanselan/formats/png/PngTextTest.java
URL: http://svn.apache.org/viewvc/commons/proper/sanselan/trunk/src/test/java/org/apache/sanselan/formats/png/PngTextTest.java?rev=995614&r1=995613&r2=995614&view=diff
==============================================================================
--- commons/proper/sanselan/trunk/src/test/java/org/apache/sanselan/formats/png/PngTextTest.java
(original)
+++ commons/proper/sanselan/trunk/src/test/java/org/apache/sanselan/formats/png/PngTextTest.java
Fri Sep 10 00:34:02 2010
@@ -75,7 +75,7 @@ public class PngTextTest extends PngBase
 		IOUtils.writeToFile(bytes, tempFile);
 
 		PngImageInfo imageInfo = (PngImageInfo) Sanselan.getImageInfo(bytes);
-		assertTrue(null != imageInfo);
+		assertNotNull(imageInfo);
 
 		List readTexts = imageInfo.getTextChunks();
 		assertEquals(readTexts.size(), 3);

Modified: commons/proper/sanselan/trunk/src/test/java/org/apache/sanselan/formats/png/PngWriteReadTest.java
URL: http://svn.apache.org/viewvc/commons/proper/sanselan/trunk/src/test/java/org/apache/sanselan/formats/png/PngWriteReadTest.java?rev=995614&r1=995613&r2=995614&view=diff
==============================================================================
--- commons/proper/sanselan/trunk/src/test/java/org/apache/sanselan/formats/png/PngWriteReadTest.java
(original)
+++ commons/proper/sanselan/trunk/src/test/java/org/apache/sanselan/formats/png/PngWriteReadTest.java
Fri Sep 10 00:34:02 2010
@@ -146,7 +146,7 @@ public class PngWriteReadTest extends Sa
 
 		BufferedImage dstImage = Sanselan.getBufferedImage(bytes);
 
-		assertTrue(null != dstImage);
+		assertNotNull(dstImage);
 		assertTrue(srcImage.getWidth() == dstImage.getWidth());
 		assertTrue(srcImage.getHeight() == dstImage.getHeight());
 
@@ -156,8 +156,8 @@ public class PngWriteReadTest extends Sa
 
 	private void compare(int[][] a, int[][] b)
 	{
-		assertTrue(null != a);
-		assertTrue(null != b);
+		assertNotNull(a);
+		assertNotNull(b);
 		assertTrue(a.length == b.length);
 
 		for (int y = 0; y < a.length; y++)



Mime
View raw message