{
getLog().debug("+++ testCreateExceptionFromInterface()");
InitialContext ctx = new InitialContext();
Object ref = ctx.lookup("ejbcts/StatelessSessionHome");
StatelessSessionHome home = (StatelessSessionHome) PortableRemoteObject.narrow(ref, StatelessSessionHome.class);
StatelessSession sessionBean = home.create();
sessionBean.breakCreate();
ObjectName pool = new ObjectName("jboss.j2ee:jndiName=ejbcts/StatelessSessionHome,plugin=pool,service=EJB");
getServer().invoke(pool, "clear", null, null);
try
{
sessionBean.method1("This should cause a CreateException");
fail("Should not be here");
}
catch (RemoteException expected)
{
log.debug("Expected", expected);