mirror of
https://github.com/tiennm99/java-design-patterns.git
synced 2026-05-20 05:27:15 +00:00
* fix: Change h2 database usage to in mem (#2366) * #2366 Add delay option
This commit is contained in:
@@ -44,7 +44,7 @@ import org.h2.jdbcx.JdbcDataSource;
|
||||
*/
|
||||
@Slf4j
|
||||
public class App {
|
||||
private static final String DB_URL = "jdbc:h2:~/dao";
|
||||
private static final String DB_URL = "jdbc:h2:mem:dao;DB_CLOSE_DELAY=-1";
|
||||
private static final String ALL_CUSTOMERS = "customerDao.getAllCustomers(): ";
|
||||
|
||||
/**
|
||||
|
||||
@@ -49,7 +49,7 @@ import org.mockito.Mockito;
|
||||
*/
|
||||
class DbCustomerDaoTest {
|
||||
|
||||
private static final String DB_URL = "jdbc:h2:~/dao";
|
||||
private static final String DB_URL = "jdbc:h2:mem:dao;DB_CLOSE_DELAY=-1";
|
||||
private DbCustomerDao dao;
|
||||
private final Customer existingCustomer = new Customer(1, "Freddy", "Krueger");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user