I have a strange problem. When I run my test in IDEA they work, but if I do it from console 'gradle test' I get:
com.easythings.teessstttt.service.ProductServiceTest > initializationError FAILED
org.jetbrains.exposed.exceptions.ExposedSQLException at ProductServiceTest.kt:29
Caused by: org.h2.jdbc.JdbcBatchUpdateException at ProductServiceTest.kt:29
Why?
I fixed it. When I started tests in IDEA I did it for a signle file and I have only one connection to the database. Using the 'gradle test' command starts all tests at the same time. I added "time now" to database name and it solved the problem.