Author: kkolinko
Date: Sat Oct 25 22:31:47 2014
New Revision: 1634257
URL: http://svn.apache.org/r1634257
Log:
Test for BZ 54928: use logging instead of System.err.
Modified:
tomcat/trunk/test/org/apache/catalina/connector/TestCoyoteAdapter.java
Modified: tomcat/trunk/test/org/apache/catalina/connector/TestCoyoteAdapter.java
URL:
http://svn.apache.org/viewvc/tomcat/trunk/test/org/apache/catalina/connector/TestCoyoteAdapter.java?rev=1634257&r1=1634256&r2=1634257&view=diff
==============================================================================
--- tomcat/trunk/test/org/apache/catalina/connector/TestCoyoteAdapter.java
(original)
+++ tomcat/trunk/test/org/apache/catalina/connector/TestCoyoteAdapter.java Sat
Oct 25 22:31:47 2014
@@ -307,8 +307,9 @@ public class TestCoyoteAdapter extends T
for (int i = 0; i < 10; i++) {
String line = client.readLine();
- if (line != null && line.length() > 20)
- System.err.println(line.subSequence(0, 20) + "...");
+ if (line != null && line.length() > 20) {
+ log.info(line.subSequence(0, 20) + "...");
+ }
}
client.disconnect();
@@ -319,13 +320,13 @@ public class TestCoyoteAdapter extends T
Thread.sleep(250);
count ++;
}
- System.err.println("Waited for servlet thread to stop for "
- + (count * 250) + " ms");
+ log.info("Waited for servlet thread to stop for " + (count * 250)
+ + " ms");
Assert.assertTrue(servlet.isCompleted());
}
- private static class AsyncServlet extends HttpServlet {
+ private class AsyncServlet extends HttpServlet {
private static final long serialVersionUID = 1L;
@@ -370,7 +371,7 @@ public class TestCoyoteAdapter extends T
os.flush();
Thread.sleep(1000);
} catch (Exception e) {
- System.err.println("Exception caught " +
e.getMessage());
+ log.info("Exception caught " + e.getMessage());
try {
// Note if request times out before this
// exception is thrown and the complete call
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]