Return-Path: Delivered-To: apmail-jakarta-commons-dev-archive@www.apache.org Received: (qmail 25040 invoked from network); 25 Sep 2006 05:17:10 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 25 Sep 2006 05:17:10 -0000 Received: (qmail 81244 invoked by uid 500); 25 Sep 2006 05:17:09 -0000 Delivered-To: apmail-jakarta-commons-dev-archive@jakarta.apache.org Received: (qmail 80688 invoked by uid 500); 25 Sep 2006 05:17:06 -0000 Mailing-List: contact commons-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Jakarta Commons Developers List" Reply-To: "Jakarta Commons Developers List" Delivered-To: mailing list commons-dev@jakarta.apache.org Received: (qmail 80677 invoked by uid 500); 25 Sep 2006 05:17:06 -0000 Received: (qmail 80673 invoked by uid 99); 25 Sep 2006 05:17:06 -0000 Received: from idunn.apache.osuosl.org (HELO idunn.apache.osuosl.org) (140.211.166.84) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 24 Sep 2006 22:17:06 -0700 Authentication-Results: idunn.apache.osuosl.org smtp.mail=psteitz@apache.org; spf=permerror X-ASF-Spam-Status: No, hits=-9.4 required=5.0 tests=ALL_TRUSTED,NO_REAL_NAME Received-SPF: error (idunn.apache.osuosl.org: domain apache.org from 140.211.166.113 cause and error) Received: from [140.211.166.113] ([140.211.166.113:54779] helo=eris.apache.org) by idunn.apache.osuosl.org (ecelerity 2.1.1.8 r(12930)) with ESMTP id 85/87-13750-15667154 for ; Sun, 24 Sep 2006 22:17:05 -0700 Received: by eris.apache.org (Postfix, from userid 65534) id 73DB61A981A; Sun, 24 Sep 2006 22:17:03 -0700 (PDT) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r449577 - /jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestConnectionPool.java Date: Mon, 25 Sep 2006 05:17:03 -0000 To: commons-cvs@jakarta.apache.org From: psteitz@apache.org X-Mailer: svnmailer-1.1.0 Message-Id: <20060925051703.73DB61A981A@eris.apache.org> X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Author: psteitz Date: Sun Sep 24 22:17:02 2006 New Revision: 449577 URL: http://svn.apache.org/viewvc?view=rev&rev=449577 Log: Added test case showing that the fix for DBCP-198 resolved DBCP-128 as well. Modified: jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestConnectionPool.java Modified: jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestConnectionPool.java URL: http://svn.apache.org/viewvc/jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestConnectionPool.java?view=diff&rev=449577&r1=449576&r2=449577 ============================================================================== --- jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestConnectionPool.java (original) +++ jakarta/commons/proper/dbcp/trunk/src/test/org/apache/commons/dbcp/TestConnectionPool.java Sun Sep 24 22:17:02 2006 @@ -21,6 +21,7 @@ import java.sql.ResultSet; import java.sql.SQLException; import java.sql.Statement; +import java.util.Hashtable; import java.util.Stack; import junit.framework.TestCase; @@ -384,6 +385,21 @@ for (int i = 0; i < c.length; i++) { c[i].close(); } + } + + /** + * DBCP-128: BasicDataSource.getConnection() + * Connections don't work as hashtable keys + */ + public void testHashing() throws Exception { + Connection con = getConnection(); + Hashtable hash = new Hashtable(); + hash.put(con, "test"); + assertEquals("test", hash.get(con)); + assertTrue(hash.containsKey(con)); + assertTrue(hash.contains("test")); + hash.clear(); + con.close(); } public void testThreaded() { --------------------------------------------------------------------- To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org For additional commands, e-mail: commons-dev-help@jakarta.apache.org