[jboss-cvs] JBossAS SVN: r85250 - trunk/testsuite/src/main/org/jboss/test/jca/test.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Wed Mar 4 14:52:42 EST 2009


Author: jesper.pedersen
Date: 2009-03-04 14:52:42 -0500 (Wed, 04 Mar 2009)
New Revision: 85250

Modified:
   trunk/testsuite/src/main/org/jboss/test/jca/test/BaseConnectionManagerUnitTestCase.java
Log:
[JBAS-6272] jrockit - org.jboss.test.jca.test.BaseConnectionManagerUnitTestCase.testAllocationRetryMultiThread

Modified: trunk/testsuite/src/main/org/jboss/test/jca/test/BaseConnectionManagerUnitTestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/jca/test/BaseConnectionManagerUnitTestCase.java	2009-03-04 19:51:47 UTC (rev 85249)
+++ trunk/testsuite/src/main/org/jboss/test/jca/test/BaseConnectionManagerUnitTestCase.java	2009-03-04 19:52:42 UTC (rev 85250)
@@ -423,7 +423,7 @@
       pp.minSize = 0;
       pp.maxSize = 6;
       pp.blockingTimeout = 100;
-      pp.idleTimeout = 500;
+      pp.idleTimeout = 2000;
 
       final BaseConnectionManager2 cm = getCM(pp, 1, 1000);
 
@@ -478,18 +478,6 @@
 
                      cont.await();
 
-                     try
-                     {
-                        ConnectionListener cl = cm.getManagedConnection(null, null);
-                        cs.add(cl);
-
-                        failedDescription = "Got a connection";
-                        failed = true;
-                     }
-                     catch (ResourceException ignore)
-                     {
-                     }
-
                      for (Iterator i = cs.iterator(); i.hasNext();)
                      {
                         cm.returnManagedConnection((ConnectionListener)i.next(), true);
@@ -509,6 +497,19 @@
          firstPart.await();
          assertTrue("2: Wrong number of connections counted: " + cm.getConnectionCount(), cm.getConnectionCount() == pp.maxSize);
 
+         try
+         {
+            ConnectionListener cl = cm.getManagedConnection(null, null);
+            cm.returnManagedConnection(cl, true);
+
+            failedDescription = "Got a connection";
+            failedException = new Exception(cl.toString());
+            failed = true;
+         }
+         catch (ResourceException ignore)
+         {
+         }
+
          cont.countDown();
 
          done.await();




More information about the jboss-cvs-commits mailing list