The next version NetBeans 6.8 includes a nice new feature: it generates Unit-Tests for EJB 3.1 with Embeddable Container code.
@Test
public void testHello() throws Exception {
System.out.println("hello");
HelloService instance = (HelloService)javax.ejb.embeddable.EJBContainer.createEJBContainer().getContext().lookup("java:global/classes/HelloService");
String expResult = "";
String result = instance.hello();
assertEquals(expResult, result);
// TODO review the generated test code and remove the default call to fail.
fail("The test case is a prototype.");
}