Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 4818 invoked from network); 11 Feb 2008 12:50:32 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 11 Feb 2008 12:50:32 -0000 Received: (qmail 25318 invoked by uid 500); 11 Feb 2008 12:50:25 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 25290 invoked by uid 500); 11 Feb 2008 12:50:25 -0000 Mailing-List: contact derby-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: Delivered-To: mailing list derby-dev@db.apache.org Received: (qmail 25281 invoked by uid 99); 11 Feb 2008 12:50:25 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 11 Feb 2008 04:50:25 -0800 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 11 Feb 2008 12:49:48 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 36DB371407C for ; Mon, 11 Feb 2008 04:50:08 -0800 (PST) Message-ID: <1201098.1202734208221.JavaMail.jira@brutus> Date: Mon, 11 Feb 2008 04:50:08 -0800 (PST) From: "Kristian Waagan (JIRA)" To: derby-dev@db.apache.org Subject: [jira] Updated: (DERBY-3306) jdbc4.StatementEventsTest cannot be run individually in a clean environment In-Reply-To: <23460018.1199875594080.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/DERBY-3306?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Kristian Waagan updated DERBY-3306: ----------------------------------- Attachment: derby-3306-1c-create_db_by_default_and_test_fixes.diff 'derby-3306-1c-create_db_by_default_and_test_fixes.diff' is a refreshed patch. Version 1b failed to apply cleanly due to other, unrelated changes in DataSourceTest. The changes made to the tests fell into one of the following categories: a) creating connections to non-existing databases b) asserting no warnings (got warning about connection to existing database) c) using connection attributes conflicting with creating a new database I haven't received any negative feedback on the patch, so I'm committing it. Note that when the patch is committed, connections created from data sources obtained through the JUnit *DataSource utility classes will have the createDatabase property set to "create" by default. > jdbc4.StatementEventsTest cannot be run individually in a clean environment > --------------------------------------------------------------------------- > > Key: DERBY-3306 > URL: https://issues.apache.org/jira/browse/DERBY-3306 > Project: Derby > Issue Type: Bug > Components: Test > Affects Versions: 10.4.0.0 > Reporter: Kristian Waagan > Assignee: Kristian Waagan > Priority: Minor > Attachments: derby-3306-1a-create_db_by_default.diff, derby-3306-1b-create_db_by_default_and_test_fixes.diff, derby-3306-1b-create_db_by_default_and_test_fixes.stat, derby-3306-1c-create_db_by_default_and_test_fixes.diff, derby-3306-errors_with_patch_1a.txt > > > jdbc4.StatementEventsTest cannot be run individually in a clean environment because the test database is not created if it does not exist. > Excerpt of output from JUnit: > 32) testErrorEventOnClosedConnection_pooled_prepared(org.apache.derbyTesting.functionTests.tests.jdbc4.StatementEventsTest)java.sql.SQLNonTransientConnectionException: The connection was refused because the database wombat was not found. > at org.apache.derby.client.am.SQLExceptionFactory40.getSQLException(SQLExceptionFactory40.java:70) > at org.apache.derby.client.am.SqlException.getSQLException(SqlException.java:362) > at org.apache.derby.client.ClientPooledConnection.(ClientPooledConnection.java:89) > at org.apache.derby.client.ClientPooledConnection40.(ClientPooledConnection40.java:47) > at org.apache.derby.client.net.ClientJDBCObjectFactoryImpl40.newClientPooledConnection(ClientJDBCObjectFactoryImpl40.java:73) > at org.apache.derby.jdbc.ClientConnectionPoolDataSource.getPooledConnectionX(ClientConnectionPoolDataSource.java:100) > at org.apache.derby.jdbc.ClientConnectionPoolDataSource.getPooledConnection(ClientConnectionPoolDataSource.java:63) > at org.apache.derbyTesting.functionTests.tests.jdbc4.StatementEventsTest.setUp(StatementEventsTest.java:125) > at org.apache.derbyTesting.junit.BaseTestCase.runBare(BaseTestCase.java:96) > at junit.extensions.TestDecorator.basicRun(TestDecorator.java:24) > at junit.extensions.TestSetup$1.protect(TestSetup.java:21) > at junit.extensions.TestSetup.run(TestSetup.java:25) > at org.apache.derbyTesting.junit.BaseTestSetup.run(BaseTestSetup.java:57) > at junit.extensions.TestDecorator.basicRun(TestDecorator.java:24) > at junit.extensions.TestSetup$1.protect(TestSetup.java:21) > at junit.extensions.TestSetup.run(TestSetup.java:25) > Caused by: org.apache.derby.client.am.DisconnectException: The connection was refused because the database wombat was not found. > at org.apache.derby.client.net.NetConnectionReply.parseRDBNFNRM(NetConnectionReply.java:1022) > at org.apache.derby.client.net.NetConnectionReply.parseAccessRdbError(NetConnectionReply.java:448) > at org.apache.derby.client.net.NetConnectionReply.parseACCRDBreply(NetConnectionReply.java:306) > at org.apache.derby.client.net.NetConnectionReply.readAccessDatabase(NetConnectionReply.java:133) > at org.apache.derby.client.net.NetConnection.readSecurityCheckAndAccessRdb(NetConnection.java:887) > at org.apache.derby.client.net.NetConnection.flowSecurityCheckAndAccessRdb(NetConnection.java:799) > at org.apache.derby.client.net.NetConnection.flowUSRIDPWDconnect(NetConnection.java:620) > at org.apache.derby.client.net.NetConnection.flowConnect(NetConnection.java:435) > at org.apache.derby.client.net.NetConnection.initialize(NetConnection.java:296) > at org.apache.derby.client.net.NetConnection.(NetConnection.java:280) > at org.apache.derby.client.net.NetConnection40.(NetConnection40.java:125) > at org.apache.derby.client.net.ClientJDBCObjectFactoryImpl40.newNetConnection(ClientJDBCObjectFactoryImpl40.java:260) > at org.apache.derby.client.ClientPooledConnection.(ClientPooledConnection.java:75) > ... 29 more > FAILURES!!! > Tests run: 32, Failures: 0, Errors: 32 -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.