db-ojb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brian McCallister <bri...@apache.org>
Subject Re: OJB 1.0.2 ?
Date Sun, 06 Mar 2005 18:05:11 GMT
Looks good, though I have 2 failures, one in QueryTest#
     /**
      * Test pathExpression and Extents
      */
     public void testReportPathExpressionForExtents2()
     {
         ArrayList list = new java.util.ArrayList();

         Criteria crit = new Criteria();
         crit.addLike("groupName", "%o%");
         crit.addLike("allArticlesInGroup.articleName", "%\u00f6%"); 
//unicode for ö

         ReportQueryByCriteria q = 
QueryFactory.newReportQuery(ProductGroup.class, crit, true);
         q.setAttributes(new String[]{"groupId", "groupName"});

         Iterator iter = broker.getReportQueryIteratorByQuery(q);
         while(iter.hasNext())
         {
             list.add(iter.next());
         }

         // Groups: 3 Books , 1 Dairy Product
         assertEquals("check size", list.size(), 2);
     }

One in SwizzleTests:
     public void testSwizzle1toN() throws Exception
     {
         clearTestData();
         Transaction tx = _kit.getTransaction(_conn);
         tx.begin();
         ProductGroup pg = new ProductGroup();
         pg.setId(new Integer(77777));
         pg.setName("1");
         _conn.makePersistent(pg);
         Article article = Article.createInstance();
         article.setArticleId(new Integer(77777));
         article.setStock(333);
         pg.add(article);
         article.setProductGroup(pg);
         _conn.makePersistent(article);
         Identity pgOid = _conn.getIdentity(pg);
         tx.commit();

         tx = _kit.getTransaction(_conn);
         tx.begin();
         pg = (ProductGroup) _conn.getObjectByIdentity(pgOid);
         pg.getAllArticlesInGroup().clear();
         tx.commit();

         tx = _kit.getTransaction(_conn);
         tx.begin();
         pg = (ProductGroup) _conn.getObjectByIdentity(pgOid);
         assertEquals("should be equal", 0, 
pg.getAllArticlesInGroup().size());
         tx.commit();

         tx = _kit.getTransaction(_conn);
         tx.begin();
         pg = (ProductGroup) _conn.getObjectByIdentity(pgOid);
         pg.getAllArticlesInGroup().add(article);
         tx.commit();

         tx = _kit.getTransaction(_conn);
         tx.begin();
         pg = (ProductGroup) _conn.getObjectByIdentity(pgOid);
         assertEquals("should be equal", 1, 
pg.getAllArticlesInGroup().size());
         tx.commit();
         clearTestData();
     }

The first is a unicode thing, which is wonky in the Apple JVM, so if it 
passes for you I don't trust my failure. Investigating the second right 
now.

-Brian

On Mar 4, 2005, at 6:52 PM, Martin Kalén wrote:

> Brian McCallister wrote:
>> Postgres has slipped downhill:
>>     [junit] Tests run: 615, Failures: 7, Errors: 12, Time elapsed: 
>> 211.185 sec
>>     [junit] Test org.apache.ojb.broker.AllTests FAILED
>>     [junit] Running org.apache.ojb.odmg.AllTests
>>     [junit] Tests run: 129, Failures: 0, Errors: 0, Time elapsed: 
>> 26.91 sec
>>     [junit] Running org.apache.ojb.soda.AllTests
>>     [junit] Tests run: 3, Failures: 0, Errors: 0, Time elapsed: 4.406 
>> sec
>>     [junit] Running org.apache.ojb.otm.AllTests
>>     [junit] Tests run: 79, Failures: 1, Errors: 0, Time elapsed: 
>> 18.614 sec
>>     [junit] Test org.apache.ojb.otm.AllTests FAILED
>
> Brian; I've changed some stuff after looking at your test output -- 
> could you please re-test?
>
> With the latest stuff from OJB_1_0_BRANCH I get the following with
> PostgreSQL 8.0.1 and postgresql-8.0.309.jdbc2.jar JDBC-driver:
>
> [junit] Running org.apache.ojb.broker.AllTests
> [junit] Tests run: 615, Failures: 0, Errors: 0, Time elapsed: 142,125 
> sec
> [junit] Running org.apache.ojb.odmg.AllTests
> [junit] Tests run: 129, Failures: 0, Errors: 0, Time elapsed: 16,235 
> sec
>
> [junit] Running org.apache.ojb.soda.AllTests
> [junit] Tests run: 3, Failures: 0, Errors: 0, Time elapsed: 2,516 sec
>
> [junit] Running org.apache.ojb.otm.AllTests
> [junit] Tests run: 79, Failures: 1, Errors: 0, Time elapsed: 13,953 sec
> [junit] Test org.apache.ojb.otm.AllTests FAILED
>
> If your results differ, make sure that no other connection is open to 
> the TEMPLATE1 or OJBTEST database and make a full "ant clean junit", 
> to avoid any stale testdata from old testruns.
>
> Regards,
>  Martin
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
> For additional commands, e-mail: ojb-dev-help@db.apache.org
>
>


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


Mime
View raw message