commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r636923 - in /commons/proper/net/trunk/src/test/org/apache/commons/net/telnet: InvalidTelnetOptionExceptionTest.java TelnetClientFunctionalTest.java TelnetTestResponder.java
Date Thu, 13 Mar 2008 23:36:25 GMT
Author: sebb
Date: Thu Mar 13 16:36:22 2008
New Revision: 636923

URL: http://svn.apache.org/viewvc?rev=636923&view=rev
Log:
Remove redundant new String()

Modified:
    commons/proper/net/trunk/src/test/org/apache/commons/net/telnet/InvalidTelnetOptionExceptionTest.java
    commons/proper/net/trunk/src/test/org/apache/commons/net/telnet/TelnetClientFunctionalTest.java
    commons/proper/net/trunk/src/test/org/apache/commons/net/telnet/TelnetTestResponder.java

Modified: commons/proper/net/trunk/src/test/org/apache/commons/net/telnet/InvalidTelnetOptionExceptionTest.java
URL: http://svn.apache.org/viewvc/commons/proper/net/trunk/src/test/org/apache/commons/net/telnet/InvalidTelnetOptionExceptionTest.java?rev=636923&r1=636922&r2=636923&view=diff
==============================================================================
--- commons/proper/net/trunk/src/test/org/apache/commons/net/telnet/InvalidTelnetOptionExceptionTest.java
(original)
+++ commons/proper/net/trunk/src/test/org/apache/commons/net/telnet/InvalidTelnetOptionExceptionTest.java
Thu Mar 13 16:36:22 2008
@@ -42,7 +42,7 @@
      ***/
     protected void setUp()
     {
-        msg1 = new String("MSG");
+        msg1 = "MSG";
         code1 = 13;
         exc1 = new InvalidTelnetOptionException(msg1, code1);
     }

Modified: commons/proper/net/trunk/src/test/org/apache/commons/net/telnet/TelnetClientFunctionalTest.java
URL: http://svn.apache.org/viewvc/commons/proper/net/trunk/src/test/org/apache/commons/net/telnet/TelnetClientFunctionalTest.java?rev=636923&r1=636922&r2=636923&view=diff
==============================================================================
--- commons/proper/net/trunk/src/test/org/apache/commons/net/telnet/TelnetClientFunctionalTest.java
(original)
+++ commons/proper/net/trunk/src/test/org/apache/commons/net/telnet/TelnetClientFunctionalTest.java
Thu Mar 13 16:36:22 2008
@@ -99,7 +99,7 @@
         byte buffer[] = new byte[32];
         long starttime = System.currentTimeMillis();
 
-        String readbytes = new String();
+        String readbytes = "";
         while((readbytes.indexOf(end) < 0) &&
               ((System.currentTimeMillis() - starttime) < timeout))
         {

Modified: commons/proper/net/trunk/src/test/org/apache/commons/net/telnet/TelnetTestResponder.java
URL: http://svn.apache.org/viewvc/commons/proper/net/trunk/src/test/org/apache/commons/net/telnet/TelnetTestResponder.java?rev=636923&r1=636922&r2=636923&view=diff
==============================================================================
--- commons/proper/net/trunk/src/test/org/apache/commons/net/telnet/TelnetTestResponder.java
(original)
+++ commons/proper/net/trunk/src/test/org/apache/commons/net/telnet/TelnetTestResponder.java
Thu Mar 13 16:36:22 2008
@@ -67,7 +67,7 @@
 
         try
         {
-            String readbytes = new String();
+            String readbytes = "";
             while(!result &&
                   ((System.currentTimeMillis() - starttime) < _timeout))
             {



Mime
View raw message