From torque-dev-return-10655-apmail-db-torque-dev-archive=db.apache.org@db.apache.org Fri Dec 9 20:09:52 2011 Return-Path: X-Original-To: apmail-db-torque-dev-archive@www.apache.org Delivered-To: apmail-db-torque-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8D14E7276 for ; Fri, 9 Dec 2011 20:09:52 +0000 (UTC) Received: (qmail 38330 invoked by uid 500); 9 Dec 2011 20:09:52 -0000 Delivered-To: apmail-db-torque-dev-archive@db.apache.org Received: (qmail 38308 invoked by uid 500); 9 Dec 2011 20:09:52 -0000 Mailing-List: contact torque-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Apache Torque Developers List" Reply-To: "Apache Torque Developers List" Delivered-To: mailing list torque-dev@db.apache.org Received: (qmail 38300 invoked by uid 500); 9 Dec 2011 20:09:52 -0000 Received: (qmail 38297 invoked by uid 99); 9 Dec 2011 20:09:52 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 09 Dec 2011 20:09:52 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 09 Dec 2011 20:09:50 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id E9CCE23888FD; Fri, 9 Dec 2011 20:09:29 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1212607 - /db/torque/torque4/trunk/torque-test/src/test/java/org/apache/torque/generated/peer/DeleteTest.java Date: Fri, 09 Dec 2011 20:09:29 -0000 To: torque-commits@db.apache.org From: tfischer@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20111209200929.E9CCE23888FD@eris.apache.org> Author: tfischer Date: Fri Dec 9 20:09:29 2011 New Revision: 1212607 URL: http://svn.apache.org/viewvc?rev=1212607&view=rev Log: Remove trailing spaces Modified: db/torque/torque4/trunk/torque-test/src/test/java/org/apache/torque/generated/peer/DeleteTest.java Modified: db/torque/torque4/trunk/torque-test/src/test/java/org/apache/torque/generated/peer/DeleteTest.java URL: http://svn.apache.org/viewvc/db/torque/torque4/trunk/torque-test/src/test/java/org/apache/torque/generated/peer/DeleteTest.java?rev=1212607&r1=1212606&r2=1212607&view=diff ============================================================================== --- db/torque/torque4/trunk/torque-test/src/test/java/org/apache/torque/generated/peer/DeleteTest.java (original) +++ db/torque/torque4/trunk/torque-test/src/test/java/org/apache/torque/generated/peer/DeleteTest.java Fri Dec 9 20:09:29 2011 @@ -66,16 +66,16 @@ public class DeleteTest extends BaseRunt public void testDeleteByObject() throws Exception { ForeignKeySchemaData.clearTablesInDatabase(); - ForeignKeySchemaData testData + ForeignKeySchemaData testData = ForeignKeySchemaData.getDefaultTestData(); testData.save(); - NullableOIntegerFk toDelete + NullableOIntegerFk toDelete = testData.getNullableOIntegerFkList().get(0); int preDeleteId = toDelete.getId(); // check that three entries are in the NullableOIntegerFk table - List nullableOIntegerFkList + List nullableOIntegerFkList = getNullableOIntegerFkList(); assertEquals(3, nullableOIntegerFkList.size()); assertTrue(nullableOIntegerFkList.contains(toDelete)); @@ -106,17 +106,17 @@ public class DeleteTest extends BaseRunt public void testDeleteByObjectNoMatch() throws Exception { ForeignKeySchemaData.clearTablesInDatabase(); - ForeignKeySchemaData testData + ForeignKeySchemaData testData = ForeignKeySchemaData.getDefaultTestData(); testData.save(); - NullableOIntegerFk toDelete + NullableOIntegerFk toDelete = testData.getNullableOIntegerFkList().get(0); toDelete.setId(toDelete.getId() - 1); int preDeleteId = toDelete.getId(); // check that three entries are in the NullableOIntegerFk table - List nullableOIntegerFkList + List nullableOIntegerFkList = getNullableOIntegerFkList(); assertEquals(3, nullableOIntegerFkList.size()); assertFalse(nullableOIntegerFkList.contains(toDelete)); @@ -140,17 +140,17 @@ public class DeleteTest extends BaseRunt public void testDeleteByObjectChangedNopkColumn() throws Exception { ForeignKeySchemaData.clearTablesInDatabase(); - ForeignKeySchemaData testData + ForeignKeySchemaData testData = ForeignKeySchemaData.getDefaultTestData(); testData.save(); - NullableOIntegerFk toDelete + NullableOIntegerFk toDelete = testData.getNullableOIntegerFkList().get(0); toDelete.setName("nullableOIntegerFk2Changed"); int preDeleteId = toDelete.getId(); // check that three entries are in the NullableOIntegerFk table - List nullableOIntegerFkList + List nullableOIntegerFkList = getNullableOIntegerFkList(); assertEquals(3, nullableOIntegerFkList.size()); assertTrue(nullableOIntegerFkList.contains(toDelete)); @@ -193,7 +193,7 @@ public class DeleteTest extends BaseRunt assertEquals(1, deleted); // check that there are two entries remaining in the database - // and the toDelete object was deleted + // and the toDelete object was deleted // (use intcol for latter as equals does not work) nopkList = getNopkList(); assertEquals(2, nopkList.size()); @@ -228,7 +228,7 @@ public class DeleteTest extends BaseRunt assertEquals(0, deleted); // check that there are all entries remaining in the database - // and the toDelete object is still there + // and the toDelete object is still there // (use intcol for latter as equals does not work) nopkList = getNopkList(); assertEquals(3, nopkList.size()); @@ -244,11 +244,11 @@ public class DeleteTest extends BaseRunt public void testDeleteByObjectCollection() throws Exception { ForeignKeySchemaData.clearTablesInDatabase(); - ForeignKeySchemaData testData + ForeignKeySchemaData testData = ForeignKeySchemaData.getDefaultTestData(); testData.save(); - List toDelete + List toDelete = new ArrayList(); toDelete.add(testData.getNullableOIntegerFkList().get(0)); toDelete.add(testData.getNullableOIntegerFkList().get(2)); @@ -257,7 +257,7 @@ public class DeleteTest extends BaseRunt preDeleteIds.add(toDelete.get(1).getId()); // check that three entries are in the NullableOIntegerFk table - List nullableOIntegerFkList + List nullableOIntegerFkList = getNullableOIntegerFkList(); assertEquals(3, nullableOIntegerFkList.size()); assertTrue(nullableOIntegerFkList.contains(toDelete.get(0))); @@ -292,11 +292,11 @@ public class DeleteTest extends BaseRunt public void testDeleteByObjectCollectionNoMatch() throws Exception { ForeignKeySchemaData.clearTablesInDatabase(); - ForeignKeySchemaData testData + ForeignKeySchemaData testData = ForeignKeySchemaData.getDefaultTestData(); testData.save(); - List toDelete + List toDelete = new ArrayList(); toDelete.add(testData.getNullableOIntegerFkList().get(0)); toDelete.add(testData.getNullableOIntegerFkList().get(2)); @@ -305,7 +305,7 @@ public class DeleteTest extends BaseRunt // check that three entries are in the NullableOIntegerFk table // prior to deletion - List nullableOIntegerFkList + List nullableOIntegerFkList = getNullableOIntegerFkList(); assertEquals(3, nullableOIntegerFkList.size()); assertFalse(nullableOIntegerFkList.contains(toDelete.get(0))); @@ -330,16 +330,16 @@ public class DeleteTest extends BaseRunt public void testDeleteByPrimaryKey() throws Exception { ForeignKeySchemaData.clearTablesInDatabase(); - ForeignKeySchemaData testData + ForeignKeySchemaData testData = ForeignKeySchemaData.getDefaultTestData(); testData.save(); - NullableOIntegerFk toDelete + NullableOIntegerFk toDelete = testData.getNullableOIntegerFkList().get(0); int preDeleteId = toDelete.getId(); // check that three entries are in the NullableOIntegerFk table - List nullableOIntegerFkList + List nullableOIntegerFkList = getNullableOIntegerFkList(); assertEquals(3, nullableOIntegerFkList.size()); assertTrue(nullableOIntegerFkList.contains(toDelete)); @@ -376,17 +376,17 @@ public class DeleteTest extends BaseRunt public void testDeleteByPrimaryKeyNoMatch() throws Exception { ForeignKeySchemaData.clearTablesInDatabase(); - ForeignKeySchemaData testData + ForeignKeySchemaData testData = ForeignKeySchemaData.getDefaultTestData(); testData.save(); - NullableOIntegerFk toDelete + NullableOIntegerFk toDelete = testData.getNullableOIntegerFkList().get(0); toDelete.setId(toDelete.getId() - 1); int preDeleteId = toDelete.getId(); // check that three entries are in the NullableOIntegerFk table - List nullableOIntegerFkList + List nullableOIntegerFkList = getNullableOIntegerFkList(); assertEquals(3, nullableOIntegerFkList.size()); assertFalse(nullableOIntegerFkList.contains(toDelete)); @@ -408,13 +408,13 @@ public class DeleteTest extends BaseRunt /** * Checks that rows can be deleted by a Criteria. - * + * * @throws Exception if a database error occurs */ public void testDeleteByCriteria() throws Exception { ForeignKeySchemaData.clearTablesInDatabase(); - ForeignKeySchemaData testData + ForeignKeySchemaData testData = ForeignKeySchemaData.getDefaultTestData(); testData.save(); @@ -426,10 +426,10 @@ public class DeleteTest extends BaseRunt Criteria.LESS_EQUAL); int deletedCount = NullableOIntegerFkPeer.doDelete(criteria); assertEquals(2, deletedCount); - + // check that only the last entry remains in the NullableOIntegerFk // table - List nullableOIntegerFkList + List nullableOIntegerFkList = getNullableOIntegerFkList(); assertEquals(1, nullableOIntegerFkList.size()); assertEquals( @@ -444,13 +444,13 @@ public class DeleteTest extends BaseRunt /** * Checks that a non-matching Criteria does not delete any rows. - * + * * @throws Exception if a database error occurs */ public void testDeleteByCriteriaNoMatch() throws Exception { ForeignKeySchemaData.clearTablesInDatabase(); - ForeignKeySchemaData testData + ForeignKeySchemaData testData = ForeignKeySchemaData.getDefaultTestData(); testData.save(); @@ -459,9 +459,9 @@ public class DeleteTest extends BaseRunt criteria.and(NullableOIntegerFkPeer.NAME, "noMatch"); int deletedCount = NullableOIntegerFkPeer.doDelete(criteria); assertEquals(0, deletedCount); - + // check that three entries remain in the NullableOIntegerFk table - List nullableOIntegerFkList + List nullableOIntegerFkList = getNullableOIntegerFkList(); assertEquals(3, nullableOIntegerFkList.size()); } @@ -469,20 +469,20 @@ public class DeleteTest extends BaseRunt /** * Checks that delete fails if a column from another table is added. * See TORQUE-113 - * + * * @throws Exception if a database error occurs */ public void testDeleteWithOtherTableColumn() throws Exception { ForeignKeySchemaData.clearTablesInDatabase(); - ForeignKeySchemaData testData + ForeignKeySchemaData testData = ForeignKeySchemaData.getDefaultTestData(); testData.save(); // call delete method Criteria criteria = new Criteria(); criteria.and( - OIntegerPkPeer.ID, + OIntegerPkPeer.ID, testData.getOIntegerPkList().get(0).getId()); try { @@ -497,16 +497,16 @@ public class DeleteTest extends BaseRunt /** * Checks that delete by criteria using a join works correctly. - * This test accepts two results: Either an exception is thrown + * This test accepts two results: Either an exception is thrown * (i.e the database does not support join clauses in delete statements) * or deletion works correctly. - * + * * @throws Exception if a database error occurs */ public void testDeleteByCriteriaWithJoins() throws Exception { ForeignKeySchemaData.clearTablesInDatabase(); - ForeignKeySchemaData testData + ForeignKeySchemaData testData = ForeignKeySchemaData.getDefaultTestData(); testData.save(); @@ -517,7 +517,7 @@ public class DeleteTest extends BaseRunt OIntegerPkPeer.ID, SqlEnum.INNER_JOIN); criteria.and( - OIntegerPkPeer.ID, + OIntegerPkPeer.ID, testData.getOIntegerPkList().get(0).getId()); try { @@ -529,10 +529,10 @@ public class DeleteTest extends BaseRunt log.debug("Delete by joins does not work for this database."); return; } - + // check that the last two entries remains in the NullableOIntegerFk // table - List nullableOIntegerFkList + List nullableOIntegerFkList = getNullableOIntegerFkList(); assertEquals(2, nullableOIntegerFkList.size()); assertTrue(nullableOIntegerFkList.contains( @@ -549,7 +549,7 @@ public class DeleteTest extends BaseRunt /** * Checks that delete by criteria throws an exception if a non-matching * condition is added. - * + * * @throws Exception if a database error occurs */ public void testDeleteByCriteriaWithWrongTable() throws Exception @@ -570,9 +570,9 @@ public class DeleteTest extends BaseRunt /** * Reads all NullableOIntegerFk rows from the database. - * + * * @return the NullableOIntegerFk rows - * + * * @throws TorqueException if reading fails. */ // TODO to ForeignKeyTestData @@ -581,16 +581,16 @@ public class DeleteTest extends BaseRunt { Criteria criteria = new Criteria(); criteria.addAscendingOrderByColumn(NullableOIntegerFkPeer.ID); - List result + List result = NullableOIntegerFkPeer.doSelect(criteria); return result; } /** * Reads all Nopk rows from the database. - * + * * @return the Nopk rows - * + * * @throws TorqueException if reading fails. */ private List getNopkList() throws TorqueException --------------------------------------------------------------------- To unsubscribe, e-mail: torque-dev-unsubscribe@db.apache.org For additional commands, e-mail: torque-dev-help@db.apache.org