assertTrue(thrown);  conn.close();
   public void testCommitIllegalState() throws Exception   {      Connection conn = cf.createConnection();      Session producerSess = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);      boolean thrown = false;      try      {         producerSess.commit();      }      catch (javax.jms.IllegalStateException e)      {         thrown = true;      }      assertTrue(thrown);      conn.close();   }