Currently, I am using below configuration my test classes-
@TransactionConfiguration(transactionManager = "transactionManager", defaultRollback = false)
@Transactional
As @TransactionConfiguration
is deprecated, What can be the replacement for that-
I have tried -
@Transactional(transactionManager = "transactionManager")
@Commit
But I am getting the below error-
java.lang.IllegalStateException: Test class [ca.aeso.dt.dao.impl.AssetAttributeDaoImplTest] is annotated with both @Rollback and @TransactionConfiguration, but only one is permitted. at org.springframework.test.context.transaction.TransactionalTestExecutionListener.isDefaultRollback(TransactionalTestExecutionListener.java:383) at org.springframework.test.context.transaction.TransactionalTestExecutionListener.isRollback(TransactionalTestExecutionListener.java:412) at org.springframework.test.context.transaction.TransactionalTestExecutionListener.beforeTestMethod(TransactionalTestExecutionListener.java:201) at org.springframework.test.context.TestContextManager.beforeTestMethod(TestContextManager.java:269)