• Views
  • Iteration Report
  • My Iteration Report
  •  
OMERO.server
  • Login
  • Help/Guide
  • About Trac
  • Preferences
  • Wiki
  • Timeline
  • Roadmap
  • Browse Source
  • View Tickets
  • Search

Context Navigation

  • ← Previous Ticket
  • Next Ticket →

Ticket #84 (closed defect: fixed)

Opened 2 years ago

Last modified 2 years ago

QueryTest and Co. are broken in TestNg.

Reported by: jmoore Owned by: jmoore
Priority: minor Milestone: 3.0-M2
Component: Deployment Version: 3.0-M1
Keywords: iteration2,testing Cc:

Description

All subclasses of the Spring transaction-managing test are broken with testng. The configuration of the context is somehow going amiss.

ome.conditions.InternalException:  Wrapped Exception: (org.springframework.transaction.IllegalTransactionStateException):
Pre-bound JDBC Connection found - HibernateTransactionManager does not support running within DataSourceTransactionManager if told to manage the DataSource itself. It is recommended to use a single HibernateTransactionManager for all transactions on a single DataSource, no matter whether Hibernate or JDBC access.
	at org.springframework.orm.hibernate3.HibernateTransactionManager.doBegin(HibernateTransactionManager.java:430)
	at org.springframework.transaction.support.AbstractPlatformTransactionManager.getTransaction(AbstractPlatformTransactionManager.java:283)
	at org.springframework.transaction.interceptor.TransactionAspectSupport.createTransactionIfNecessary(TransactionAspectSupport.java:234)
 	at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:93)

Change History

Changed 2 years ago by jmoore

  • status changed from new to assigned

http://tearesolutions.com/blog/?p=9 seems to be explain some of these problems. Specifically, that the mixing of direct JDBC and Hibernate managed calls can lead to problems. This has apparently surfaced with the TestNG-ification of our JUnit tests.

Changed 2 years ago by jmoore

r677 updates testng framework so it can be more easily run from Eclipse. This problem has been verified in Eclipse and Ant, but only when running multiple tests from testng.xml.

Changed 2 years ago by anonymous

  • keywords iteration2,testing added; iteration2 removed
  • status changed from assigned to closed
  • resolution set to fixed

r683 cleans up tests and shows this as fixed. Currently some 127 tests are passing, 9 failing, and a dozen disabled (in server/).

Note: See TracTickets for help on using tickets.

Download in other formats:

  • Comma-delimited Text
  • Tab-delimited Text
  • RSS Feed

Trac Powered

Powered by Trac 0.11
By Edgewall Software.

Visit the Trac open source project at
http://trac.edgewall.org/