CDI/WeldとJEEUnitを使用してjunitテストを試しています。起動時に次のメッセージが表示されます。
189 [main] INFO org.jboss.weld.Bootstrap - WELD-000101 Transactional services not available. Injection of @Inject UserTransaction not available. Transactional observers will be invoked synchronously.
em.flush()
後で、トランザクションがアクティブであると期待しているため、電話をかけるとEntitymanagerが失敗します。JUnitテストに使用できる軽量のトランザクション実装はありますか?
編集:
最終的にGuiceRunnerを使用しました。これは非常に単純です... http://fabiostrozzi.eu/2011/03/27/junit-tests-easy-guice/