db-jdo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Craig Russell (JIRA)" <j...@apache.org>
Subject [jira] Commented: (JDO-423) Missing addTearDownClass in org.apache.jdo.tck.query.jdoql.variables.VariablesWithoutExtent
Date Mon, 11 Sep 2006 18:21:22 GMT
    [ http://issues.apache.org/jira/browse/JDO-423?page=comments#action_12433920 ] 
            
Craig Russell commented on JDO-423:
-----------------------------------

Michael and I looked at the test and can't see anything wrong to suggest changing the test.


As Michael noted above, the test does call addTearDownInstance in the setUp method, and during
tearDown the instance will be deleted.

Note that this is the only class that uses the addTearDownInstance method. The other tests
all use addTearDownClass.

To help debug this, you could trace the behavior of JDO_Test.deleteTearDownInstance which
is called during tearDown of each test method. One thing I'd suggest is to look at the behavior
of your implementation when getting the object id from an instance that has been created and
made persistent in a transaction that has not yet committed.

> Missing addTearDownClass in org.apache.jdo.tck.query.jdoql.variables.VariablesWithoutExtent
> -------------------------------------------------------------------------------------------
>
>                 Key: JDO-423
>                 URL: http://issues.apache.org/jira/browse/JDO-423
>             Project: JDO
>          Issue Type: Bug
>          Components: tck20
>    Affects Versions: JDO 2 final
>            Reporter: Ilan Kirsh
>            Priority: Minor
>
> Lines 101- 108, instead of:
>     protected void localSetUp() {
>         addTearDownClass(CompanyModelReader.getTearDownClasses());
>         loadAndPersistCompanyModel(getPM());
>         NoExtent noExtent = new NoExtent(1);
>         makePersistent(noExtent);
>         addTearDownInstance(noExtent);
>     }
> should be:
>     protected void localSetUp() {
>         addTearDownClass(CompanyModelReader.getTearDownClasses());
>         addTearDownClass(NoExtent.class); // Added missing addTearDownClass
>         loadAndPersistCompanyModel(getPM());
>         NoExtent noExtent = new NoExtent(1);
>         makePersistent(noExtent);
>         addTearDownInstance(noExtent);
>     }

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message