Search in sources :

Example 1 with UtilLoggingJdbcLogger

use of org.seasar.doma.jdbc.UtilLoggingJdbcLogger in project doma by domaframework.

the class LocalTransactionDataSourceTest method testGetConnection.

@Test
public void testGetConnection() {
    UtilLoggingJdbcLogger jdbcLogger = new UtilLoggingJdbcLogger();
    LocalTransactionDataSource dataSource = new LocalTransactionDataSource(new MockDataSource());
    dataSource.getLocalTransaction(jdbcLogger).begin();
    dataSource.getConnection();
    dataSource.getLocalTransaction(jdbcLogger).commit();
}
Also used : MockDataSource(org.seasar.doma.internal.jdbc.mock.MockDataSource) UtilLoggingJdbcLogger(org.seasar.doma.jdbc.UtilLoggingJdbcLogger) Test(org.junit.jupiter.api.Test)

Aggregations

Test (org.junit.jupiter.api.Test)1 MockDataSource (org.seasar.doma.internal.jdbc.mock.MockDataSource)1 UtilLoggingJdbcLogger (org.seasar.doma.jdbc.UtilLoggingJdbcLogger)1