db-torque-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From t.@apache.org
Subject svn commit: r1855052 - /db/torque/torque4/trunk/torque-test/src/test/java/org/apache/torque/ForeignKeySchemaData.java
Date Fri, 08 Mar 2019 15:52:23 GMT
Author: tv
Date: Fri Mar  8 15:52:23 2019
New Revision: 1855052

URL: http://svn.apache.org/viewvc?rev=1855052&view=rev
Log:
Fix deprecation warnings

Modified:
    db/torque/torque4/trunk/torque-test/src/test/java/org/apache/torque/ForeignKeySchemaData.java

Modified: db/torque/torque4/trunk/torque-test/src/test/java/org/apache/torque/ForeignKeySchemaData.java
URL: http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-test/src/test/java/org/apache/torque/ForeignKeySchemaData.java?rev=1855052&r1=1855051&r2=1855052&view=diff
==============================================================================
--- db/torque/torque4/trunk/torque-test/src/test/java/org/apache/torque/ForeignKeySchemaData.java
(original)
+++ db/torque/torque4/trunk/torque-test/src/test/java/org/apache/torque/ForeignKeySchemaData.java
Fri Mar  8 15:52:23 2019
@@ -19,11 +19,11 @@ package org.apache.torque;
  * under the License.
  */
 
+import static org.junit.Assert.assertEquals;
+
 import java.util.ArrayList;
 import java.util.List;
 
-import junit.framework.Assert;
-
 import org.apache.torque.criteria.Criteria;
 import org.apache.torque.om.mapper.IntegerMapper;
 import org.apache.torque.test.dbobject.CompIntegerVarcharFk;
@@ -1061,16 +1061,16 @@ public class ForeignKeySchemaData
                     throws TorqueException
     {
         Criteria criteria = new Criteria().addSelectColumn(new Count("*"));
-        Assert.assertEquals(new Integer(expected.size()),
+        assertEquals(Integer.valueOf(expected.size()),
                 NonPkOIntegerFkPeer.doSelectSingleRecord(
                         criteria, new IntegerMapper()));
         for (NonPkOIntegerFk nonPkOIntegerFk : expected)
         {
             criteria = NonPkOIntegerFkPeer.buildCriteria(nonPkOIntegerFk);
             criteria.addSelectColumn(new Count("*"));
-            Assert.assertEquals(
+            assertEquals(
                     "Expected but not found : " + nonPkOIntegerFk,
-                    new Integer(1),
+                    Integer.valueOf(1),
                     NonPkOIntegerFkPeer.doSelectSingleRecord(
                             criteria, new IntegerMapper()));
         }
@@ -1089,7 +1089,7 @@ public class ForeignKeySchemaData
                     throws TorqueException
     {
         Criteria criteria = new Criteria().addSelectColumn(new Count("*"));
-        Assert.assertEquals(new Integer(expected.size()),
+        assertEquals(Integer.valueOf(expected.size()),
                 CompIntegerVarcharFkPeer.doSelectSingleRecord(
                         criteria, new IntegerMapper()));
         for (CompIntegerVarcharFk compIntegerVarcharFk : expected)
@@ -1097,9 +1097,9 @@ public class ForeignKeySchemaData
             criteria = CompIntegerVarcharFkPeer.buildCriteria(
                     compIntegerVarcharFk);
             criteria.addSelectColumn(new Count("*"));
-            Assert.assertEquals(
+            assertEquals(
                     "Expected but not found : " + compIntegerVarcharFk,
-                    new Integer(1),
+                    Integer.valueOf(1),
                     CompIntegerVarcharFkPeer.doSelectSingleRecord(
                             criteria, new IntegerMapper()));
         }
@@ -1118,16 +1118,16 @@ public class ForeignKeySchemaData
                     throws TorqueException
     {
         Criteria criteria = new Criteria().addSelectColumn(new Count("*"));
-        Assert.assertEquals(new Integer(expected.size()),
+        assertEquals(Integer.valueOf(expected.size()),
                 NullableOIntegerFkPeer.doSelectSingleRecord(
                         criteria, new IntegerMapper()));
         for (NullableOIntegerFk nullableOIntegerFk : expected)
         {
             criteria = NullableOIntegerFkPeer.buildCriteria(nullableOIntegerFk);
             criteria.addSelectColumn(new Count("*"));
-            Assert.assertEquals(
+            assertEquals(
                     "Expected but not found : " + nullableOIntegerFk,
-                    new Integer(1),
+                    Integer.valueOf(1),
                     NullableOIntegerFkPeer.doSelectSingleRecord(
                             criteria, new IntegerMapper()));
         }
@@ -1146,16 +1146,16 @@ public class ForeignKeySchemaData
                     throws TorqueException
     {
         Criteria criteria = new Criteria().addSelectColumn(new Count("*"));
-        Assert.assertEquals(new Integer(expected.size()),
+        assertEquals(Integer.valueOf(expected.size()),
                 CompPkOtherFkPeer.doSelectSingleRecord(
                         criteria, new IntegerMapper()));
         for (CompPkOtherFk compPkOtherFk : expected)
         {
             criteria = CompPkOtherFkPeer.buildCriteria(compPkOtherFk);
             criteria.addSelectColumn(new Count("*"));
-            Assert.assertEquals(
+            assertEquals(
                     "Expected but not found : " + compPkOtherFk,
-                    new Integer(1),
+                    Integer.valueOf(1),
                     CompPkOtherFkPeer.doSelectSingleRecord(
                             criteria, new IntegerMapper()));
         }
@@ -1174,16 +1174,16 @@ public class ForeignKeySchemaData
                     throws TorqueException
     {
         Criteria criteria = new Criteria().addSelectColumn(new Count("*"));
-        Assert.assertEquals(new Integer(expected.size()),
+        assertEquals(Integer.valueOf(expected.size()),
                 CompPkContainsFkPeer.doSelectSingleRecord(
                         criteria, new IntegerMapper()));
         for (CompPkContainsFk compPkContainsFk : expected)
         {
             criteria = CompPkContainsFkPeer.buildCriteria(compPkContainsFk);
             criteria.addSelectColumn(new Count("*"));
-            Assert.assertEquals(
+            assertEquals(
                     "Expected but not found : " + compPkContainsFk,
-                    new Integer(1),
+                    Integer.valueOf(1),
                     CompPkContainsFkPeer.doSelectSingleRecord(
                             criteria, new IntegerMapper()));
         }



---------------------------------------------------------------------
To unsubscribe, e-mail: torque-dev-unsubscribe@db.apache.org
For additional commands, e-mail: torque-dev-help@db.apache.org


Mime
View raw message