db-torque-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tfisc...@apache.org
Subject svn commit: r398617 - /db/torque/test/trunk/test-project/src/java/org/apache/torque/DataTest.java
Date Mon, 01 May 2006 15:17:26 GMT
Author: tfischer
Date: Mon May  1 08:17:23 2006
New Revision: 398617

URL: http://svn.apache.org/viewcvs?rev=398617&view=rev
Log:
Added the check that null can be inserted into nullable integer columns. Checks TRQS259.

Modified:
    db/torque/test/trunk/test-project/src/java/org/apache/torque/DataTest.java

Modified: db/torque/test/trunk/test-project/src/java/org/apache/torque/DataTest.java
URL: http://svn.apache.org/viewcvs/db/torque/test/trunk/test-project/src/java/org/apache/torque/DataTest.java?rev=398617&r1=398616&r2=398617&view=diff
==============================================================================
--- db/torque/test/trunk/test-project/src/java/org/apache/torque/DataTest.java (original)
+++ db/torque/test/trunk/test-project/src/java/org/apache/torque/DataTest.java Mon May  1
08:17:23 2006
@@ -279,6 +279,7 @@
         // add test data
         NullValueTable nvt = new NullValueTable();
         nvt.setText1("text");
+        nvt.setNumberObj1(new Integer(1));
         nvt.save();
         nvt = new NullValueTable();
         nvt.setText2("text");
@@ -290,6 +291,9 @@
                 NullValueTablePeer.TEXT1, 
                 (Integer)null, 
                 Criteria.NOT_EQUAL);
+        criteria.add(NullValueTablePeer.NUMBER_OBJ1,
+                (Integer)null,
+                Criteria.NOT_EQUAL);
         List result = NullValueTablePeer.doSelect(criteria);
         assertEquals("testNullSelects()" 
                 + "Result size should be 1 but is " 
@@ -308,6 +312,9 @@
         criteria.add(
                 NullValueTablePeer.TEXT1, 
                 (Integer)null, 
+                Criteria.EQUAL);
+        criteria.add(NullValueTablePeer.NUMBER_OBJ1,
+                (Integer)null,
                 Criteria.EQUAL);
         result = NullValueTablePeer.doSelect(criteria);
         assertEquals("testNullSelects()" 



---------------------------------------------------------------------
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