ClientSessionFactory cf = createInVMFactory();
ClientSession session = cf.createSession("auser", "pass", false, true, true, false, -1);
session.createQueue(SecurityTest.addressA, SecurityTest.queueA, false);
try
{
session.deleteQueue(SecurityTest.queueA);
Assert.fail("should throw exception");
}
catch (HornetQException e)
{
Assert.assertEquals(HornetQException.SECURITY_EXCEPTION, e.getCode());