@Test
public void testTransactionsRollback() throws Exception {
final List< ? > list = new ArrayList<Object>();
PlatformTransactionManager txManager = (PlatformTransactionManager) ctx.getBean( "txManager" );
final Environment env = KnowledgeBaseFactory.newEnvironment();
env.set( EnvironmentName.ENTITY_MANAGER_FACTORY,
ctx.getBean( "myEmf" ) );
env.set( EnvironmentName.TRANSACTION_MANAGER,
txManager );
env.set( EnvironmentName.GLOBALS,
new MapGlobalResolver() );
env.set( EnvironmentName.OBJECT_MARSHALLING_STRATEGIES,
new ObjectMarshallingStrategy[]{new JPAPlaceholderResolverStrategy( env ),
new SerializablePlaceholderResolverStrategy( ClassObjectMarshallingStrategyAcceptor.DEFAULT )} );
final KnowledgeStoreService kstore = (KnowledgeStoreService) ctx.getBean( "kstore1" );
final KnowledgeBase kbRollback = (KnowledgeBase) ctx.getBean( "kbRollback" );