[ http://issues.apache.org/jira/browse/DERBY-1149?page=all ]
David Van Couvering updated DERBY-1149:
---------------------------------------
Attachment: DERBY-1149-4a-StatementTestFailure.diff
This is the patch I hope to commit. It passes all jdbc40 tests, including
StatementTest, for both embedded and network drivers.
Changes:
- Reverted engine code to use old SQL States, as discussions have shown this is
likely a break in compatibility requirements. Logged bugs DERBY-1168 and
DERBY-1169 to note the incorrect SQL states being used in the engine
- Added a new SQL State constants file which was a cut-and-paste exercise from
the SQL2003 spec. Using these constants in StatementTest.java
- I modified the assertSQLState method in BaseJDBCTestCase to not truncate the
SQL State string and to ensure that the length of the expected and received SQL
States were both 5 characters long. But I didn't actually end up using it in
the test case because I wanted to throw the actual exception encountered so
that the stack trace was printed out.
I'm running derbyall again so hoping to check in tomorrow morning unless there
are issues with the patch
> 'jdbc40/StatementTest.junit' fails under DerbyNetClient
> -------------------------------------------------------
>
> Key: DERBY-1149
> URL: http://issues.apache.org/jira/browse/DERBY-1149
> Project: Derby
> Type: Test
> Components: Regression Test Failure, Test
> Versions: 10.2.0.0
> Environment: JDK 1.6 (b76 used, believed to apply to all)
> Reporter: Kristian Waagan
> Assignee: David Van Couvering
> Attachments: DERBY-1149-2a-StatementTestFailure.diff,
> DERBY-1149-3a-StatementTestFailure.diff,
> DERBY-1149-4a-StatementTestFailure.diff, DERBY-1149-StatementTestFaiure.diff
>
> One of the tests in jdbc40/StatementTest.junit fails with the following
> message:
> "Attempt to shutdown framework: DerbyNetClient
> 0 add
> > ....F.
> > There was 1 failure:
> > 1)
> > testIsClosedWhenClosingConnectionInInvalidState(org.apache.derbyTesting.functionTests.tests.jdbc4.StatementTest)junit.framework.ComparisonFailure:
> > Unexpected exception thrown: Cannot close a connection while a global
> > transaction is still active. expected:<java.sql.Connection.close()
> > requested while a transaction is in progress on the connection.The
> > transaction remains active, and the connection cannot be closed...> but
> > was:<Cannot close a connection while a global transaction is still
> > active...>
> > FAILURES!!!
> > Tests run: 5, Failures: 1, Errors: 0
> Test Failed.
> *** End: StatementTest jdk1.6.0-beta2 DerbyNetClient 2006-03-24 12:53:22
> ***"
> The reason is that the exception message text has been changed. This
> comparison is only done when running DerbyNetClient, because SQLState was not
> implemented there.
> The checkin that caused the error:
> "Author: davidvc
> Date: Thu Mar 23 16:55:44 2006
> New Revision: 388309
> URL: http://svn.apache.org/viewcvs?rev=388309&view=rev
> Log:
> DERBY-839 (Partial). Internationalize Connection.java. Also upgraded
> the "i18n lint" test to be a little more intelligent, and to not exit
> on the first failure.
> Passes derbynetclientmats. All changes are client-specific so derbyall
> was not run."
> A
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira