commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ma...@apache.org
Subject svn commit: r1567040 - in /commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2: ./ cpdsadapter/ managed/
Date Tue, 11 Feb 2014 10:46:38 GMT
Author: markt
Date: Tue Feb 11 10:46:38 2014
New Revision: 1567040

URL: http://svn.apache.org/r1567040
Log:
Fix auto boxing warnings

Modified:
    commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestBasicDataSource.java
    commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestDriverManagerConnectionFactory.java
    commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPStmtPooling.java
    commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPoolableConnection.java
    commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPoolingDataSource.java
    commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPoolingDriver.java
    commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/cpdsadapter/TestDriverAdapterCPDS.java
    commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/managed/TestManagedDataSource.java

Modified: commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestBasicDataSource.java
URL: http://svn.apache.org/viewvc/commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestBasicDataSource.java?rev=1567040&r1=1567039&r2=1567040&view=diff
==============================================================================
--- commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestBasicDataSource.java
(original)
+++ commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestBasicDataSource.java
Tue Feb 11 10:46:38 2014
@@ -59,8 +59,8 @@ public class TestBasicDataSource extends
         ds.setUrl("jdbc:apache:commons:testdriver");
         ds.setMaxTotal(getMaxTotal());
         ds.setMaxWaitMillis(getMaxWaitMillis());
-        ds.setDefaultAutoCommit(true);
-        ds.setDefaultReadOnly(false);
+        ds.setDefaultAutoCommit(Boolean.TRUE);
+        ds.setDefaultReadOnly(Boolean.FALSE);
         ds.setDefaultTransactionIsolation(Connection.TRANSACTION_READ_COMMITTED);
         ds.setDefaultCatalog(CATALOG);
         ds.setUsername("username");
@@ -377,7 +377,7 @@ public class TestBasicDataSource extends
 
     public void testSetAutoCommitTrueOnClose() throws Exception {
         ds.setAccessToUnderlyingConnectionAllowed(true);
-        ds.setDefaultAutoCommit(false);
+        ds.setDefaultAutoCommit(Boolean.FALSE);
 
         Connection conn = getConnection();
         assertNotNull(conn);
@@ -451,8 +451,8 @@ public class TestBasicDataSource extends
      * trying to commit or rollback a readOnly connection.
      */
     public void testRollbackReadOnly() throws Exception {
-        ds.setDefaultReadOnly(true);
-        ds.setDefaultAutoCommit(false);
+        ds.setDefaultReadOnly(Boolean.TRUE);
+        ds.setDefaultAutoCommit(Boolean.FALSE);
 
         Connection conn = ds.getConnection();
         assertNotNull(conn);
@@ -488,8 +488,8 @@ public class TestBasicDataSource extends
         ds.setUrl("jdbc:apache:commons:testdriver");
         ds.setMaxTotal(getMaxTotal());
         ds.setMaxWaitMillis(getMaxWaitMillis());
-        ds.setDefaultAutoCommit(true);
-        ds.setDefaultReadOnly(false);
+        ds.setDefaultAutoCommit(Boolean.TRUE);
+        ds.setDefaultReadOnly(Boolean.FALSE);
         ds.setDefaultTransactionIsolation(Connection.TRANSACTION_READ_COMMITTED);
         ds.setDefaultCatalog(CATALOG);
         ds.setUsername("username");

Modified: commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestDriverManagerConnectionFactory.java
URL: http://svn.apache.org/viewvc/commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestDriverManagerConnectionFactory.java?rev=1567040&r1=1567039&r2=1567040&view=diff
==============================================================================
--- commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestDriverManagerConnectionFactory.java
(original)
+++ commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestDriverManagerConnectionFactory.java
Tue Feb 11 10:46:38 2014
@@ -57,8 +57,8 @@ public class TestDriverManagerConnection
                     "foo", "bar");
         final PoolableConnectionFactory poolableConnectionFactory =
             new PoolableConnectionFactory(connectionFactory, null);
-        poolableConnectionFactory.setDefaultReadOnly(false);
-        poolableConnectionFactory.setDefaultAutoCommit(true);
+        poolableConnectionFactory.setDefaultReadOnly(Boolean.FALSE);
+        poolableConnectionFactory.setDefaultAutoCommit(Boolean.TRUE);
 
         GenericObjectPool<PoolableConnection> connectionPool =
                 new GenericObjectPool<>(poolableConnectionFactory, config);

Modified: commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPStmtPooling.java
URL: http://svn.apache.org/viewvc/commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPStmtPooling.java?rev=1567040&r1=1567039&r2=1567040&view=diff
==============================================================================
--- commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPStmtPooling.java
(original)
+++ commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPStmtPooling.java
Tue Feb 11 10:46:38 2014
@@ -57,8 +57,8 @@ public class TestPStmtPooling extends Te
         PoolableConnectionFactory pcf =
             new PoolableConnectionFactory(connFactory, null);
         pcf.setPoolStatements(true);
-        pcf.setDefaultReadOnly(false);
-        pcf.setDefaultAutoCommit(true);
+        pcf.setDefaultReadOnly(Boolean.FALSE);
+        pcf.setDefaultAutoCommit(Boolean.TRUE);
         ObjectPool<PoolableConnection> connPool = new GenericObjectPool<>(pcf);
 
         DataSource ds = new PoolingDataSource<>(connPool);
@@ -82,8 +82,8 @@ public class TestPStmtPooling extends Te
         PoolableConnectionFactory pcf =
             new PoolableConnectionFactory(connFactory, null);
         pcf.setPoolStatements(true);
-        pcf.setDefaultReadOnly(false);
-        pcf.setDefaultAutoCommit(true);
+        pcf.setDefaultReadOnly(Boolean.FALSE);
+        pcf.setDefaultAutoCommit(Boolean.TRUE);
 
         ObjectPool<PoolableConnection> connPool = new GenericObjectPool<>(pcf);
 
@@ -121,8 +121,8 @@ public class TestPStmtPooling extends Te
         PoolableConnectionFactory pcf =
             new PoolableConnectionFactory(connFactory, null);
         pcf.setPoolStatements(true);
-        pcf.setDefaultReadOnly(false);
-        pcf.setDefaultAutoCommit(true);
+        pcf.setDefaultReadOnly(Boolean.FALSE);
+        pcf.setDefaultAutoCommit(Boolean.TRUE);
 
         ObjectPool<PoolableConnection> connPool = new GenericObjectPool<>(pcf);
 
@@ -153,8 +153,8 @@ public class TestPStmtPooling extends Te
         PoolableConnectionFactory pcf =
             new PoolableConnectionFactory(connFactory, null);
         pcf.setPoolStatements(true);
-        pcf.setDefaultReadOnly(false);
-        pcf.setDefaultAutoCommit(true);
+        pcf.setDefaultReadOnly(Boolean.FALSE);
+        pcf.setDefaultAutoCommit(Boolean.TRUE);
         ObjectPool<PoolableConnection> connPool = new GenericObjectPool<>(pcf);
         pcf.setPool(connPool);
 

Modified: commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPoolableConnection.java
URL: http://svn.apache.org/viewvc/commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPoolableConnection.java?rev=1567040&r1=1567039&r2=1567040&view=diff
==============================================================================
--- commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPoolableConnection.java
(original)
+++ commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPoolableConnection.java
Tue Feb 11 10:46:38 2014
@@ -48,8 +48,8 @@ public class TestPoolableConnection exte
                 new DriverConnectionFactory(
                         new TesterDriver(),"jdbc:apache:commons:testdriver", null),
                 null);
-        factory.setDefaultAutoCommit(true);
-        factory.setDefaultReadOnly(true);
+        factory.setDefaultAutoCommit(Boolean.TRUE);
+        factory.setDefaultReadOnly(Boolean.TRUE);
 
         pool = new GenericObjectPool<>(factory);
         factory.setPool(pool);

Modified: commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPoolingDataSource.java
URL: http://svn.apache.org/viewvc/commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPoolingDataSource.java?rev=1567040&r1=1567039&r2=1567040&view=diff
==============================================================================
--- commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPoolingDataSource.java
(original)
+++ commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPoolingDataSource.java
Tue Feb 11 10:46:38 2014
@@ -60,8 +60,8 @@ public class TestPoolingDataSource exten
                             "jdbc:apache:commons:testdriver", props),
                     null);
         factory.setValidationQuery("SELECT DUMMY FROM DUAL");
-        factory.setDefaultReadOnly(true);
-        factory.setDefaultAutoCommit(true);
+        factory.setDefaultReadOnly(Boolean.TRUE);
+        factory.setDefaultAutoCommit(Boolean.TRUE);
         pool = new GenericObjectPool<>(factory);
         factory.setPool(pool);
         pool.setMaxTotal(getMaxTotal());

Modified: commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPoolingDriver.java
URL: http://svn.apache.org/viewvc/commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPoolingDriver.java?rev=1567040&r1=1567039&r2=1567040&view=diff
==============================================================================
--- commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPoolingDriver.java
(original)
+++ commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/TestPoolingDriver.java
Tue Feb 11 10:46:38 2014
@@ -64,8 +64,8 @@ public class TestPoolingDriver extends T
         pcf.setPoolStatements(true);
         pcf.setMaxOpenPrepatedStatements(10);
         pcf.setValidationQuery("SELECT COUNT(*) FROM DUAL");
-        pcf.setDefaultReadOnly(false);
-        pcf.setDefaultAutoCommit(true);
+        pcf.setDefaultReadOnly(Boolean.FALSE);
+        pcf.setDefaultAutoCommit(Boolean.TRUE);
 
         GenericObjectPoolConfig poolConfig = new GenericObjectPoolConfig();
         poolConfig.setMaxTotal(getMaxTotal());
@@ -96,8 +96,8 @@ public class TestPoolingDriver extends T
         ConnectionFactory connectionFactory = new DriverManagerConnectionFactory("jdbc:some:connect:string","username","password");
         PoolableConnectionFactory pcf =
             new PoolableConnectionFactory(connectionFactory, null);
-        pcf.setDefaultReadOnly(false);
-        pcf.setDefaultAutoCommit(true);
+        pcf.setDefaultReadOnly(Boolean.FALSE);
+        pcf.setDefaultAutoCommit(Boolean.TRUE);
         GenericObjectPool<PoolableConnection> connectionPool =
                 new GenericObjectPool<>(pcf);
         @SuppressWarnings("unused") // Ensure PoolingDataSource can be created
@@ -108,8 +108,8 @@ public class TestPoolingDriver extends T
         ConnectionFactory connectionFactory = new DriverManagerConnectionFactory("jdbc:some:connect:string","username","password");
         PoolableConnectionFactory pcf =
             new PoolableConnectionFactory(connectionFactory, null);
-        pcf.setDefaultReadOnly(false);
-        pcf.setDefaultAutoCommit(true);
+        pcf.setDefaultReadOnly(Boolean.FALSE);
+        pcf.setDefaultAutoCommit(Boolean.TRUE);
         GenericObjectPool<PoolableConnection> connectionPool = new GenericObjectPool<>(pcf);
         PoolingDriver driver2 = new PoolingDriver();
         driver2.registerPool("example",connectionPool);
@@ -148,8 +148,8 @@ public class TestPoolingDriver extends T
             "password");
         PoolableConnectionFactory poolableConnectionFactory =
             new PoolableConnectionFactory(connectionFactory, null);
-        poolableConnectionFactory.setDefaultReadOnly(false);
-        poolableConnectionFactory.setDefaultAutoCommit(true);
+        poolableConnectionFactory.setDefaultReadOnly(Boolean.FALSE);
+        poolableConnectionFactory.setDefaultAutoCommit(Boolean.TRUE);
         ObjectPool<PoolableConnection> connectionPool =
                 new GenericObjectPool<>(poolableConnectionFactory,config);
         poolableConnectionFactory.setPool(connectionPool);

Modified: commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/cpdsadapter/TestDriverAdapterCPDS.java
URL: http://svn.apache.org/viewvc/commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/cpdsadapter/TestDriverAdapterCPDS.java?rev=1567040&r1=1567039&r2=1567040&view=diff
==============================================================================
--- commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/cpdsadapter/TestDriverAdapterCPDS.java
(original)
+++ commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/cpdsadapter/TestDriverAdapterCPDS.java
Tue Feb 11 10:46:38 2014
@@ -18,7 +18,6 @@
 package org.apache.commons.dbcp2.cpdsadapter;
 
 import java.util.Properties;
-
 import java.sql.Connection;
 import java.sql.PreparedStatement;
 import java.sql.ResultSet;
@@ -177,7 +176,7 @@ public class TestDriverAdapterCPDS exten
         spds.setMaxTotal(threads.length + 10);
         spds.setMaxWaitMillis(-1);
         spds.setMaxIdle(10);
-        spds.setDefaultAutoCommit(false);
+        spds.setDefaultAutoCommit(Boolean.FALSE);
 
         spds.setValidationQuery("SELECT 1");
         spds.setTimeBetweenEvictionRunsMillis(10000);

Modified: commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/managed/TestManagedDataSource.java
URL: http://svn.apache.org/viewvc/commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/managed/TestManagedDataSource.java?rev=1567040&r1=1567039&r2=1567040&view=diff
==============================================================================
--- commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/managed/TestManagedDataSource.java
(original)
+++ commons/proper/dbcp/trunk/src/test/java/org/apache/commons/dbcp2/managed/TestManagedDataSource.java
Tue Feb 11 10:46:38 2014
@@ -81,8 +81,8 @@ public class TestManagedDataSource exten
         PoolableConnectionFactory factory =
             new PoolableConnectionFactory(xaConnectionFactory, null);
         factory.setValidationQuery("SELECT DUMMY FROM DUAL");
-        factory.setDefaultReadOnly(true);
-        factory.setDefaultAutoCommit(true);
+        factory.setDefaultReadOnly(Boolean.TRUE);
+        factory.setDefaultAutoCommit(Boolean.TRUE);
 
         // create the pool
         pool = new GenericObjectPool<>(factory);



Mime
View raw message