Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Critical
-
Resolution: Fixed
-
Affects Version/s: 1.1.4
-
Fix Version/s: 1.2.0-BETA1
-
Component/s: None
-
Labels:None
Description
All new records are stored in the identityMap during insertion. This default behavior takes place also while executing test cases.
In other words every record created in the prepareData() method gets to the identityMap. Afterwards, in a test method, it is silently retrived from identityMap instead of (expected!) quering from sqlite.
IMHO a testing environment should be as pure as possible and no such side effects are acceptable.
I'm including a test case and patch for Doctrine_UnitTestCase. After putting the patch, I have found that 2 test cases causes fail: 1449 and 736. In the first test IMHO there is a problem in a content test - I'm including appropriate fix.
It seems that the second test, in fact, have never been passing. I think that positive result was caused by the side effect of identityMap.
This breaks the 1.2 test suite. Can you retry your patch?