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 dj...@apache.org on 2007/02/13 22:44:14 UTC
svn commit: r507242 - in
/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang:
AIjdbc.java CharUTF8.java _Suite.java
Author: djd
Date: Tue Feb 13 13:44:13 2007
New Revision: 507242
URL: http://svn.apache.org/viewvc?view=rev&rev=507242
Log:
Add old harness lang tests that successfully run under the JUnit infrastructure using the LangHarnessJavaTest.
Separate commit will remove the files from the old harness.
Modified:
db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/AIjdbc.java
db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/CharUTF8.java
db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/_Suite.java
Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/AIjdbc.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/AIjdbc.java?view=diff&rev=507242&r1=507241&r2=507242
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/AIjdbc.java (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/AIjdbc.java Tue Feb 13 13:44:13 2007
@@ -63,6 +63,8 @@
// do a select from a view.
passed = testSelectView(conn) && passed;
+
+ conn.close();
}
catch (Throwable e)
{
@@ -91,6 +93,7 @@
s = conn.createStatement();
s.execute("create table tab1 (x int, y int generated always as identity,z char(2))");
s.execute("create view tab1_view (a,b) as select y,y+1 from tab1");
+ s.close();
}
catch (SQLException se)
{
@@ -133,6 +136,7 @@
if (rsmd.isAutoIncrement(3))
throw new SQLException("column 2 is NOT ai!");
rs.close();
+ s.close();
}
catch (SQLException se)
{
@@ -161,6 +165,7 @@
throw new SQLException("column 1 IS ai!");
if (rsmd.isAutoIncrement(2))
throw new SQLException("column 1 is NOT ai!");
+ s.close();
}
catch (SQLException sqle)
{
Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/CharUTF8.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/CharUTF8.java?view=diff&rev=507242&r1=507241&r2=507242
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/CharUTF8.java (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/CharUTF8.java Tue Feb 13 13:44:13 2007
@@ -57,6 +57,7 @@
Statement st2 = conn.createStatement();
st2.execute("CREATE TABLE TEST(id int not null primary key, body varchar(60))");
+ st2.close();
psSet = conn.prepareStatement("insert into test values(?,?)");
psGet = conn.prepareStatement("select body from test where id=?");
@@ -92,6 +93,8 @@
System.out.println("FAIL: empty string returned as " + getBody(-1));
}
+ psSet.close();
+ psGet.close();
conn.close();
Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/_Suite.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/_Suite.java?view=diff&rev=507242&r1=507241&r2=507242
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/_Suite.java (original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/lang/_Suite.java Tue Feb 13 13:44:13 2007
@@ -84,6 +84,10 @@
// Add the NIST suite in from the nist package since
// it is a SQL language related test.
suite.addTest(NistScripts.suite());
+
+ // Add the java tests that run using a master
+ // file (ie. partially converted).
+ suite.addTest(LangHarnessJavaTest.suite());
// Tests that are compiled using 1.4 target need to
// be added this way, otherwise creating the suite