Author: steve.ebersole(a)jboss.com
Date: 2007-09-21 12:24:13 -0400 (Fri, 21 Sep 2007)
New Revision: 14018
Modified:
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/ConnectionProviderBuilder.java
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/batch/BasicBatchTest.java
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/batch/TestingServiceImpl.java
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/delegation/TestingServiceImpl.java
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/impl/BasicConnectionTests.java
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/impl/TestingServiceImpl.java
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/proxy/TestingServiceImpl.java
Log:
basic cleanup/doc
Modified:
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/ConnectionProviderBuilder.java
===================================================================
---
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/ConnectionProviderBuilder.java 2007-09-21
16:21:18 UTC (rev 14017)
+++
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/ConnectionProviderBuilder.java 2007-09-21
16:24:13 UTC (rev 14018)
@@ -22,7 +22,8 @@
import org.hibernate.connection.DriverManagerConnectionProvider;
/**
- * ConnectionProviderBuilder implementation
+ * Centralize building of connections for these tests. Essentially we are just
+ * hard-coding shared connection information, but in a central place.
*
* @author Steve Ebersole
*/
Modified:
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/batch/BasicBatchTest.java
===================================================================
---
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/batch/BasicBatchTest.java 2007-09-21
16:21:18 UTC (rev 14017)
+++
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/batch/BasicBatchTest.java 2007-09-21
16:24:13 UTC (rev 14018)
@@ -36,7 +36,7 @@
import org.hibernate.jdbc.proxy.ProxyBuilder;
/**
- * BasicBatchTest implementation
+ * Unit test of batching functionality
*
* @author Steve Ebersole
*/
@@ -185,7 +185,7 @@
try {
Connection conn = ProxyBuilder.buildConnection( lc );
ResultSet rs = conn.createStatement().executeQuery( "select count(*) from
SANDBOX_JDBC_TST" );
- assert true == rs.next();
+ assert rs.next();
return rs.getInt( 1 );
}
finally {
Modified:
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/batch/TestingServiceImpl.java
===================================================================
---
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/batch/TestingServiceImpl.java 2007-09-21
16:21:18 UTC (rev 14017)
+++
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/batch/TestingServiceImpl.java 2007-09-21
16:24:13 UTC (rev 14018)
@@ -24,7 +24,8 @@
import org.hibernate.jdbc.util.SQLStatementLogger;
/**
- * TestingServiceImpl implementation
+ * Implementation of the {@link JDBCServices} contract for use by these
+ * tests.
*
* @author Steve Ebersole
*/
Modified:
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/delegation/TestingServiceImpl.java
===================================================================
---
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/delegation/TestingServiceImpl.java 2007-09-21
16:21:18 UTC (rev 14017)
+++
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/delegation/TestingServiceImpl.java 2007-09-21
16:24:13 UTC (rev 14018)
@@ -24,7 +24,8 @@
import org.hibernate.connection.ConnectionProvider;
/**
- * TestingServiceImpl implementation
+ * Implementation of the {@link JDBCServices} contract for use by these
+ * tests.
*
* @author Steve Ebersole
*/
Modified:
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/impl/BasicConnectionTests.java
===================================================================
---
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/impl/BasicConnectionTests.java 2007-09-21
16:21:18 UTC (rev 14017)
+++
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/impl/BasicConnectionTests.java 2007-09-21
16:24:13 UTC (rev 14018)
@@ -20,8 +20,6 @@
import java.sql.SQLException;
import java.sql.Statement;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
import static org.testng.Assert.assertFalse;
import static org.testng.Assert.assertTrue;
import org.testng.annotations.AfterClass;
@@ -31,13 +29,11 @@
import org.hibernate.ConnectionReleaseMode;
/**
- * BasicConnectionTests implementation
+ * Here we are testing the "manual" approach to registration/cleanup.
*
* @author Steve Ebersole
*/
public class BasicConnectionTests {
- private static final Logger log = LoggerFactory.getLogger( BasicConnectionTests.class
);
-
private TestingServiceImpl services = new TestingServiceImpl();
@BeforeClass
Modified:
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/impl/TestingServiceImpl.java
===================================================================
---
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/impl/TestingServiceImpl.java 2007-09-21
16:21:18 UTC (rev 14017)
+++
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/impl/TestingServiceImpl.java 2007-09-21
16:24:13 UTC (rev 14018)
@@ -15,8 +15,6 @@
*/
package org.hibernate.jdbc.impl;
-import java.sql.SQLException;
-
import org.hibernate.jdbc.JDBCServices;
import org.hibernate.jdbc.JDBCContainerBuilder;
import org.hibernate.jdbc.ConnectionProviderBuilder;
@@ -25,7 +23,8 @@
import org.hibernate.connection.ConnectionProvider;
/**
- * TestingServiceImpl implementation
+ * Implementation of the {@link JDBCServices} contract for use by these
+ * tests.
*
* @author Steve Ebersole
*/
Modified:
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/proxy/TestingServiceImpl.java
===================================================================
---
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/proxy/TestingServiceImpl.java 2007-09-21
16:21:18 UTC (rev 14017)
+++
sandbox/trunk/jdbc-proxy/src/test/java/org/hibernate/jdbc/proxy/TestingServiceImpl.java 2007-09-21
16:24:13 UTC (rev 14018)
@@ -15,8 +15,6 @@
*/
package org.hibernate.jdbc.proxy;
-import java.sql.SQLException;
-
import org.hibernate.jdbc.JDBCServices;
import org.hibernate.jdbc.JDBCContainerBuilder;
import org.hibernate.jdbc.ConnectionProviderBuilder;
@@ -26,7 +24,8 @@
import org.hibernate.connection.ConnectionProvider;
/**
- * TestingServiceImpl implementation
+ * Implementation of the {@link JDBCServices} contract for use by these
+ * tests.
*
* @author Steve Ebersole
*/
Show replies by date