aspose file tools*
The moose likes Other Application Frameworks and the fly likes Spring 2.5 / AbstractTransactionalJUnit4SpringContextTests/ datasource Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Frameworks » Other Application Frameworks
Bookmark "Spring 2.5 / AbstractTransactionalJUnit4SpringContextTests/ datasource" Watch "Spring 2.5 / AbstractTransactionalJUnit4SpringContextTests/ datasource" New topic
Author

Spring 2.5 / AbstractTransactionalJUnit4SpringContextTests/ datasource

Santosh Ramachandrula
Ranch Hand

Joined: Apr 04, 2004
Posts: 252
Hi, I have two data-sources in my application context. In my test method I want to access both the data-sources, How do I achieve this?

For single data-source I am using the below and it works fine.



Thanks,
Santosh
Hong Anderson
Ranch Hand

Joined: Jul 05, 2005
Posts: 1936
I think you cannot, as AbstractTransactionalJUnit4SpringContextTests accepts only one data source.
You may look at source code and try to override some methods, but I guess it would be a lot of work.


SCJA 1.0, SCJP 1.4, SCWCD 1.4, SCBCD 1.3, SCJP 5.0, SCEA 5, SCBCD 5; OCUP - Fundamental, Intermediate and Advanced; IBM Certified Solution Designer - OOAD, vUML 2; SpringSource Certified Spring Professional
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Spring 2.5 / AbstractTransactionalJUnit4SpringContextTests/ datasource
 
Similar Threads
EJB environment question.
Connection to data source on the basis of userlogin using JPA
Help!!! I can't get BMT working with Orion and MS SQL Server
Problem with database connect
Database access in Struts using data-sources