Search in sources :

Example 1 with AuditInterceptorFactory

use of org.mifos.framework.hibernate.helper.AuditInterceptorFactory in project head by mifos.

the class MifosIntegrationTestCase method after.

@After
public void after() throws Exception {
    diableCustomWorkingDays();
    TestUtils.dereferenceObjects(this);
    DatabaseDependentTest.after(new AuditInterceptorFactory(), sessionFactory);
    dbVerificationTearDown();
}
Also used : AuditInterceptorFactory(org.mifos.framework.hibernate.helper.AuditInterceptorFactory) After(org.junit.After)

Example 2 with AuditInterceptorFactory

use of org.mifos.framework.hibernate.helper.AuditInterceptorFactory in project head by mifos.

the class MifosIntegrationTestCase method before.

@Before
public void before() throws Exception {
    new TestCaseInitializer().initialize(sessionFactory);
    dbVerificationSetUp();
    DatabaseDependentTest.before(new AuditInterceptorFactory(), sessionFactory);
    Money.setDefaultCurrency(TestUtils.RUPEE);
}
Also used : AuditInterceptorFactory(org.mifos.framework.hibernate.helper.AuditInterceptorFactory) TestCaseInitializer(org.mifos.framework.util.helpers.TestCaseInitializer) Before(org.junit.Before)

Example 3 with AuditInterceptorFactory

use of org.mifos.framework.hibernate.helper.AuditInterceptorFactory in project head by mifos.

the class TestCaseInitializer method initializeDB.

private void initializeDB(SessionFactory sessionFactory) throws Exception {
    StaticHibernateUtil.initialize(new AuditInterceptorFactory(), sessionFactory);
    Money.setDefaultCurrency(AccountingRules.getMifosCurrency(new ConfigurationPersistence()));
    FinancialInitializer.initialize();
    ActivityMapper.getInstance().init();
    HierarchyManager.getInstance().init();
    AuditConfiguration.init(Localization.getInstance().getConfiguredLocale());
    AccountingRules.init();
    StaticHibernateUtil.commitTransaction();
}
Also used : ConfigurationPersistence(org.mifos.config.persistence.ConfigurationPersistence) AuditInterceptorFactory(org.mifos.framework.hibernate.helper.AuditInterceptorFactory)

Aggregations

AuditInterceptorFactory (org.mifos.framework.hibernate.helper.AuditInterceptorFactory)3 After (org.junit.After)1 Before (org.junit.Before)1 ConfigurationPersistence (org.mifos.config.persistence.ConfigurationPersistence)1 TestCaseInitializer (org.mifos.framework.util.helpers.TestCaseInitializer)1