@Test public void test(){ String name = "a name"; assertFalse(queriesEJB.isInDB(name)); try { ejb.createTwoCopies(name); fail(); } catch (EJBException e){ } assertFalse(queriesEJB.isInDB(name)); }
public void createTwoCopies(String name){ Foo foo = new Foo(name); Foo copy = new Foo(name); em.persist(foo); em.persist(copy); }
EJB_02_abort { public void createTwoCopies(String name){ Foo foo = new Foo(name); Foo copy = new Foo(name); em.persist(foo); em.persist(copy); } }
EJB_02_abort { public void createTwoCopies(String name){ Foo foo = new Foo(name); Foo copy = new Foo(name); em.persist(foo); em.persist(copy); }  }
EJB_02_abort { public void createTwoCopies(String name){ Foo foo = new Foo(name); Foo copy = new Foo(name); em.persist(foo); em.persist(copy); }  void createTwoCopies(String name); }
EJB_02_abort { public void createTwoCopies(String name){ Foo foo = new Foo(name); Foo copy = new Foo(name); em.persist(foo); em.persist(copy); }  void createTwoCopies(String name);  }