|
[
Permlink
| « Hide
]
Craig Russell added a comment - 23/Apr/06 09:40 PM
Please review this patch. The patch deletes the three instances created in pm2.
Craig Russell made changes - 23/Apr/06 09:40 PM
I had to delete old database files manually one time to make this patch work because the cleanup is done only on success (It is preferred to clean pm2 at the beginning of the test rather than at the end, as done with pm1...). Anyway, now that the test case passes, I can run it multiple times without problems. Thanks.
Please review this patch.
I noticed that this test will fail if the implementation does not support binary compatibility, since the classes will not be compatible with the reference implementation if enhanced without regard for binary compatibility.
Craig Russell made changes - 23/Apr/06 09:54 PM
I don't understand the last comment. I am working now on ObjectDB 2.0 that unlike ObjectDB 1.0 will not support binary compatibility, but the test case passes now.
Anyway, I remember that in some cases (maybe in this specific test), I had to use a clean database also to pass the JDOTCK 1.0 with ObjectDB 1.0 that did support binary compatibility. The test uses the same classes with another PersistenceManager (pm2) of the jdo refererence implementation (JPOX). It does not make sense to execute the test if the JDO implementation under test does not support binary compatibility, because then there is gurantee that the enhanced classes work with the jdo refererence implementation.
One comment about the patch: I propose to delete the pm2 instances in the finally block. Then they get removed even if the test case fails. What do you think? Thank you for the clarification. I now understand this is useless if binary compatibility is not supported. Maybe you can add a check before starting the test that binary compatibility is supported? Similar check is also needed in the org.apache.jdo.tck.enhancement tests. Deleting in finally could be good, but I think that deletePersistentAll of all the PCRect and PCPoint at the beginning of the test might be even better. Anyway, it doesn't make much different.
I extended Craig's patch and added two things:
- Exit the test method if the binary compatibility option is not supported. - Remove pm2 instances in the finally block of the test method. Please have a look. Ilan, you are right, the enhancement tests need to check the binary compatibiliyt option, too. But since they are on the TCK exclude list, they are currently not executed.
Michael Bouschen made changes - 24/Apr/06 12:16 AM
Both new patches (independently) look good. I just hope I followed all the changes exactly because I copied them manually. I am running the tests in the Eclipse IDE so I didn't notice the exclude list - where can I see it?
Thanks for the review.
You find the exclude list in tck20/src/conf/exclude.list. It is automatically taken into account when running the tck from maven (e.g maven runtck.jdori or maven runtck.iut).
Michael Bouschen made changes - 24/Apr/06 01:04 AM
Hi Michael,
The patch looks good.
Checked in the patch in the 2.0 branch and the trunk (see revision 396521).
Michael Bouschen made changes - 24/Apr/06 06:46 PM
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||