This is how I start the embedded GlassFish server. It is through my main UnitTest class.
@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(locations = {"/test-context.xml" ,"/jpa-dao-context.xml"})
@Stateless
public class AppTest extends TestCase {
private static EJBContainer ejbContainer;
/**
* @throws Exception
*/
@BeforeClass
public static void setUpClass() throws Exception {
ejbContainer = EJBContainer.createEJBContainer();
}
[Message sent by forum member 'fericit_bostan']
http://forums.java.net/jive/thread.jspa?messageID=475261