I am writing a TestNG integration test for an application that uses <tx:ejb-transaction />.
The test accesses seam components during both FacesRequest.applyRequestValues() and FacesRequest.renderResponse(), and the components hit the database at both phases.
applyRequestValues() is executed properly but at renderResponse(), it says that the transaction is marked for rollback:
ERROR [org.hibernate.util.JDBCExceptionReporter] Transaction is not active: tx=TransactionImple < ac, BasicAction: a170dae:8ba:4bb238b0:69 status: ActionStatus.ABORT_ONLY >; - nested throwable: (javax.resource.ResourceException: Transaction is not active: tx=TransactionImple < ac, BasicAction: a170dae:8ba:4bb238b0:69 status: ActionStatus.ABORT_ONLY >) ERROR [org.jboss.aspects.tx.TxPolicy] javax.ejb.EJBTransactionRolledbackException: org.hibernate.exception.GenericJDBCException: Cannot open connection
No exceptions are thrown before that. I am using Seam 2.1.0 and JBoss 4.2.3
Do you know why the transaction is marked for rollback and how it can be fixed?
Thank you in advance,
Found the problem. There was an error in the page action, and the exception was not printed out