[jira] [Commented] (CAY-1560) CayenneCase tests conversion

2011-04-24 Thread Andrus Adamchik (JIRA)

[ 
https://issues.apache.org/jira/browse/CAY-1560?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13024616#comment-13024616
 ] 

Andrus Adamchik commented on CAY-1560:
--

Just committed another batch of patches. A did some edits to address the 
following things:

1. DataContext can be injected in a unit test directly if needed. So no need to 
inject ObjectContext and then do a cast to DataContext within each test case. 
See ServerCaseModule for the full list of injectable objects.

2. per r1096311 and r1096312, I altered FlattenedPrefetchTest.patch and 
DataContextObjectTrackingTest.patch. Dzmitry removed the calls to  
blockQueries() / unblockQueries() , which are no longer available in the new 
API. But we need a replacement to assert that no interaction with the DB 
happens for certain tested blocks of code (e.g. when we are asserting that 
cache is used instead of DB fetch). So the replacement is 
DataChannelInterceptor.runWithQueriesBlocked (..). DataChannelInterceptor 
itself is injectable.

Still have 9 patches to process...

 CayenneCase tests conversion
 

 Key: CAY-1560
 URL: https://issues.apache.org/jira/browse/CAY-1560
 Project: Cayenne
  Issue Type: Task
Reporter: Dzmitry Kazimirchyk
Priority: Minor
 Attachments: CDOMapRelationshipTest.patch, 
 CDOSetRelationshipTest.patch, DataContextExtrasTest.patch, 
 DataContextJoinAliasesTest.patch, DataContextObjectTrackingTest.patch, 
 DataContextPaginatedQueryTest.patch, DataContextPrefetchExtrasTest.patch, 
 DataContextQualifiedEntityTest.patch, 
 DataContextQueryCachingOSCacheTest.patch, DataContextQueryCachingTest.patch, 
 DataContextRefreshQueryTest.patch, DataContextSerializationTest.patch, 
 DeleteObjectTest.patch, EmbeddingTest.patch, FlattenedPrefetchTest.patch, 
 FlattenedRelationshipsTest.patch, JointPrefetchTest.patch, 
 MixedPersistenceStrategyTest.patch, ObjectStoreDiffRetainingTest.patch, 
 OptimisticLockingTest.patch, RemoteIncrementalFaultListTest.patch, 
 SelectQueryFetchLimitOrderingTest.patch, 
 SimpleIdIncrementalFaultListDataRowsTest.patch, 
 SimpleIdIncrementalFaultTest.patch


 Convert old CayenneCase unit tests to ServerCase tests.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira


[jira] [Commented] (CAY-1560) CayenneCase tests conversion

2011-04-22 Thread Andrus Adamchik (JIRA)

[ 
https://issues.apache.org/jira/browse/CAY-1560?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13023412#comment-13023412
 ] 

Andrus Adamchik commented on CAY-1560:
--

Hi Dzmitry. Great to see the tests getting converted from the old format. I 
already applied 9 patches from this list. I noticed one issue that causes build 
failures on Derby and H2 (not sure why not HSQLDB) - data delete order matters, 
so if you delete data from the table that is referenced via FK's from another 
table, there will be build errors. So I did some reordering of delete 
operations (r1096039). Going forward please take this into account.

 CayenneCase tests conversion
 

 Key: CAY-1560
 URL: https://issues.apache.org/jira/browse/CAY-1560
 Project: Cayenne
  Issue Type: Task
Reporter: Dzmitry Kazimirchyk
Priority: Minor
 Attachments: CDOMapRelationshipTest.patch, 
 CDOSetRelationshipTest.patch, DataContextExtrasTest.patch, 
 DataContextJoinAliasesTest.patch, DataContextObjectTrackingTest.patch, 
 DataContextPaginatedQueryTest.patch, DataContextPrefetchExtrasTest.patch, 
 DataContextQualifiedEntityTest.patch, 
 DataContextQueryCachingOSCacheTest.patch, DataContextQueryCachingTest.patch, 
 DataContextRefreshQueryTest.patch, DataContextSerializationTest.patch, 
 DeleteObjectTest.patch, EmbeddingTest.patch, FlattenedPrefetchTest.patch, 
 FlattenedRelationshipsTest.patch, JointPrefetchTest.patch, 
 MixedPersistenceStrategyTest.patch, ObjectStoreDiffRetainingTest.patch, 
 OptimisticLockingTest.patch, RemoteIncrementalFaultListTest.patch, 
 SelectQueryFetchLimitOrderingTest.patch, 
 SimpleIdIncrementalFaultListDataRowsTest.patch, 
 SimpleIdIncrementalFaultTest.patch


 Convert old CayenneCase unit tests to ServerCase tests.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira