db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rhille...@apache.org
Subject svn commit: r575060 - /db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/TableFunctionTest.java
Date Wed, 12 Sep 2007 20:07:51 GMT
Author: rhillegas
Date: Wed Sep 12 13:07:51 2007
New Revision: 575060

URL: http://svn.apache.org/viewvc?rev=575060&view=rev
Log:
DERBY-716: Apply UTF8 encoding to Strings created from byte arrays in TableFunctionTest.

Modified:
    db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/TableFunctionTest.java

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/TableFunctionTest.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/TableFunctionTest.java?rev=575060&r1=575059&r2=575060&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/TableFunctionTest.java
(original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/TableFunctionTest.java
Wed Sep 12 13:07:51 2007
@@ -47,6 +47,8 @@
     //
     ///////////////////////////////////////////////////////////////////////////////////
 
+    private static  final   String  UTF8 = "UTF8";
+    
     // functions to drop at teardown time
     private static  final   String[]    FUNCTION_NAMES =
     {
@@ -1526,7 +1528,7 @@
         {
             Blob    blob = (Blob) obj;
 
-            return new String( blob.getBytes( (long) 0, (int) blob.length() ) );
+            return new String( blob.getBytes( (long) 0, (int) blob.length() ), UTF8 );
         }
         else if ( obj instanceof Clob )
         {
@@ -1538,7 +1540,7 @@
         {
             byte[]  bytes = (byte[]) obj;
 
-            return new String( bytes );
+            return new String( bytes, UTF8 );
         }
         else { return obj.toString(); }
     }



Mime
View raw message