Moved over some of the security stuff from Photos.
[utils] / security / src / test / resources / spring / test.org.wamblee.security.database.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd">
3
4 <!-- This is the Spring configuration to define the database-related stuff for the
5     all persistence tests.  -->
6 <beans>
7     
8     <bean id="sessionFactory" class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
9         <property name="dataSource">
10             <ref bean="dataSource"/>
11         </property>
12         <property name="hibernateProperties">
13             <props>
14                 <prop key="hibernate.dialect">${hibernate.dialect}</prop>
15                 <prop key="hibernate.cache.provider_class">${hibernate.cache.provider}</prop>
16                 <prop key="hibernate.show_sql">${hibernate.show_sql}</prop>
17                 <prop key="hibernate.cache.use_query_cache">${hibernate.cache.use_query_cache}</prop>
18             </props>
19         </property>
20         <property name="mappingResources"><ref bean="hibernateMappingFiles"/></property>
21     </bean>
22     
23     <bean id="transactionManager"
24         class="org.springframework.orm.hibernate3.HibernateTransactionManager">
25         <property name="sessionFactory">
26             <ref local="sessionFactory"/>
27         </property>
28     </bean>
29     
30     <!--  Hibernate template used within test code for addition 
31             Hibernate-specific stuff -->
32     <bean id="org.springframework.orm.hibernate3.HibernateTemplate" 
33         class="org.springframework.orm.hibernate3.HibernateTemplate">
34         <property name="sessionFactory">
35             <ref bean="sessionFactory"/>
36         </property>
37     </bean>
38 </beans>