Author: markt Date: Mon Nov 13 12:34:34 2017 New Revision: 1815094 URL: http://svn.apache.org/viewvc?rev=1815094&view=rev Log: Few more static imports
Modified: tomcat/tc7.0.x/trunk/test/org/apache/coyote/http11/filters/TestFlushableGZIPOutputStream.java tomcat/tc7.0.x/trunk/test/org/apache/tomcat/util/http/mapper/TestMapper.java Modified: tomcat/tc7.0.x/trunk/test/org/apache/coyote/http11/filters/TestFlushableGZIPOutputStream.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/test/org/apache/coyote/http11/filters/TestFlushableGZIPOutputStream.java?rev=1815094&r1=1815093&r2=1815094&view=diff ============================================================================== --- tomcat/tc7.0.x/trunk/test/org/apache/coyote/http11/filters/TestFlushableGZIPOutputStream.java (original) +++ tomcat/tc7.0.x/trunk/test/org/apache/coyote/http11/filters/TestFlushableGZIPOutputStream.java Mon Nov 13 12:34:34 2017 @@ -27,7 +27,6 @@ import java.util.Arrays; import java.util.List; import java.util.zip.GZIPInputStream; -import static org.junit.Assert.assertArrayEquals; import org.junit.Assert; import org.junit.Test; @@ -80,7 +79,7 @@ public class TestFlushableGZIPOutputStre byte[] decompressedBytes = sink.toByteArray(); int originalLength = 0; for (byte[] bytes : parts) { - assertArrayEquals(bytes, Arrays.copyOfRange(decompressedBytes, + Assert.assertArrayEquals(bytes, Arrays.copyOfRange(decompressedBytes, originalLength, originalLength + bytes.length)); originalLength += bytes.length; } @@ -124,7 +123,7 @@ public class TestFlushableGZIPOutputStre byte[] decompressedBytes = sink.toByteArray(); Assert.assertEquals(data.length * 4, decompressedBytes.length); for (int i = 0; i < 4; i++) { - assertArrayEquals(data, Arrays.copyOfRange(decompressedBytes, + Assert.assertArrayEquals(data, Arrays.copyOfRange(decompressedBytes, data.length * i, data.length * (i + 1))); } } Modified: tomcat/tc7.0.x/trunk/test/org/apache/tomcat/util/http/mapper/TestMapper.java URL: http://svn.apache.org/viewvc/tomcat/tc7.0.x/trunk/test/org/apache/tomcat/util/http/mapper/TestMapper.java?rev=1815094&r1=1815093&r2=1815094&view=diff ============================================================================== --- tomcat/tc7.0.x/trunk/test/org/apache/tomcat/util/http/mapper/TestMapper.java (original) +++ tomcat/tc7.0.x/trunk/test/org/apache/tomcat/util/http/mapper/TestMapper.java Mon Nov 13 12:34:34 2017 @@ -20,7 +20,6 @@ import java.util.Arrays; import java.util.Collection; import java.util.concurrent.atomic.AtomicBoolean; -import static org.junit.Assert.assertSame; import org.junit.Assert; import org.junit.Before; import org.junit.Test; @@ -182,9 +181,9 @@ public class TestMapper extends LoggingB Assert.assertEquals("zzzz_alias1", mapper.hosts[17].name); Assert.assertEquals("zzzz_alias2", mapper.hosts[18].name); Assert.assertEquals(2, mapper.hosts[16].getAliases().size()); - assertSame(contextZ, + Assert.assertSame(contextZ, mapper.hosts[16].contextList.contexts[0].versions[0].object); - assertSame(contextZ, + Assert.assertSame(contextZ, mapper.hosts[18].contextList.contexts[0].versions[0].object); } @@ -205,12 +204,12 @@ public class TestMapper extends LoggingB Mapper.Host aliasMapping = mapper.hosts[iowPos + 1]; Assert.assertEquals("iowejoiejfoiew_alias", aliasMapping.name); Assert.assertTrue(aliasMapping.isAlias()); - assertSame(hostMapping.object, aliasMapping.object); + Assert.assertSame(hostMapping.object, aliasMapping.object); Assert.assertEquals("iowejoiejfoiew", hostMapping.getRealHostName()); Assert.assertEquals("iowejoiejfoiew", aliasMapping.getRealHostName()); - assertSame(hostMapping, hostMapping.getRealHost()); - assertSame(hostMapping, aliasMapping.getRealHost()); + Assert.assertSame(hostMapping, hostMapping.getRealHost()); + Assert.assertSame(hostMapping, aliasMapping.getRealHost()); mapper.removeHost("iowejoiejfoiew"); Assert.assertEquals(14, mapper.hosts.length); // Both host and alias removed --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org