You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-dev@db.apache.org by Armin Waibel <ar...@code-au-lait.de> on 2003/02/19 12:31:50 UTC

[OJB test failures] some really nasty bugs

Hi all,

I add some new test cases posted by Users (thanks Charles, Oliver and
all I forget)
and do some modifications to point out the problems (I hope so;-)).

1. UserTestCases
Test testImplicitLocking() fail when implicit locking was set to
'false',
the test pass when implicit locking was 'true'.
The test change the 'useImplicitLocking' property to 'false'
to simulate the situation.

2. FieldConversionForeignKeyTest/ConvertedKeyReferenceTest
This was the really nasty bug!
Both test cases use field conversions. It seems that in some cases
PK fields are not converted.

For example in StatementManager#bindSelect(...) method, the given
Identity object seems to wrap unconverted pk values, when I do a
field conversion in this method all seems ok, but now in some cases
the field conversion was done twice (ConvertedKeyReferenceTest)
on the same values. This is tragic when using a field conversion
like TestIntToIntConverter.

I think one part of the problem could be Identity, because it is
possible to make Identity instances with converted pk values
and without!
new Identity(Object objectToIdentitify, PersistenceBroker targetBroker)
--> without conversion
new Identity(Class aClass, Object[] CONVERTEDpkValues)
--> with converted pk valuse

Any suggestions?

regards,
Armin