You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-commits@db.apache.org by da...@apache.org on 2006/04/01 01:06:37 UTC
svn commit: r390536 [12/12] - in /db/derby/code/trunk:
java/build/org/apache/derbyBuild/ java/client/org/apache/derby/client/am/
java/client/org/apache/derby/loc/ java/engine/org/apache/derby/loc/
java/shared/org/apache/derby/shared/common/reference/ j...
Modified: db/derby/code/trunk/tools/testing/i18nTestGenerator/clientPrologue.txt
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/tools/testing/i18nTestGenerator/clientPrologue.txt?rev=390536&r1=390535&r2=390536&view=diff
==============================================================================
--- db/derby/code/trunk/tools/testing/i18nTestGenerator/clientPrologue.txt (original)
+++ db/derby/code/trunk/tools/testing/i18nTestGenerator/clientPrologue.txt Fri Mar 31 15:06:34 2006
@@ -11,7 +11,7 @@
* See tools/testing/i18nTestGenerator/generateClientMessageTest.sh
*/
public class TestClientMessages {
- private static Exception e;
+ private static Exception testException;
private static String feature = "testFeature";
public static void main(String[] args) {
Modified: db/derby/code/trunk/tools/testing/i18nTestGenerator/genClient2.sed
URL: http://svn.apache.org/viewcvs/db/derby/code/trunk/tools/testing/i18nTestGenerator/genClient2.sed?rev=390536&r1=390535&r2=390536&view=diff
==============================================================================
--- db/derby/code/trunk/tools/testing/i18nTestGenerator/genClient2.sed (original)
+++ db/derby/code/trunk/tools/testing/i18nTestGenerator/genClient2.sed Fri Mar 31 15:06:34 2006
@@ -2,7 +2,7 @@
# a try block and create a SqlException to complete the expression
/^[[:space:]]*new MessageId/i\
try { \
- e = new SqlException(null,
+ testException = new SqlException(null,
# For those expressions that start with "new SqlException", pre-append
# a try block
@@ -16,13 +16,13 @@
// We can get this on an assertion failure \
t.printStackTrace(); \
} \
- if ( e.getMessage().startsWith("UNKNOWN") ) {\
- e.printStackTrace(); \
+ if ( testException.getMessage().startsWith("UNKNOWN") ) {\
+ testException.printStackTrace(); \
System.err.println("FAILURE: message id was not found"); \
}
#
-# Add substitution for various string parameters where you replace
+# Add substitution for various message parameters where you replace
# the variable with a string containing the variable. This prevents
# compile errors saying "symbol not found"
#
@@ -32,6 +32,14 @@
s/Configuration.dncDriverName/"Configuration.dncDriverName"/g
s/[^\.]packageNameForDNC/"packageNameForDNC"/g
s/source,/"source",/g
+s/Types.getTypeString([^)]*)/"targetType"/g
+s/encoding/"encoding"/g
+s/source.getClass().getName()/"source"/g
+s/e.getException()/new Exception("foo")/g
+s/[[:space:]]e);/testException);/
+s/e.getClass().getName()/"exceptionClassName"/g
+s/[[:space:]]sourceType/"sourceType"/g
+s/[[:space:]]targetType/ "targetType"/g
#
# Subsitute Long and Integer params with 0 as a default
@@ -43,7 +51,7 @@
s/new SqlException[[:space:]]*(.*,/new SqlException(null,/g
# Don't throw, just assign
-s/throw new/e = new/g
+s/throw new/testException = new/g
# There are some odd situations where there is one too many parens
s/)))/))/g