Queue queue = new Queue(1, ms, pm, true, false, 100, 20, 10, new QueuedExecutor(), null);
Queue queue = new Queue(1, ms, pm, true, false, 100, 20, 10, new QueuedExecutor());
   public void testNonRecoverableQueueRemoveAllReferences() throws Throwable   {      //Non recoverable queue - eg temporary queue            Queue queue = new Queue(1, ms, pm, true, false, 100, 20, 10, new QueuedExecutor(), null);            Message[] msgs = new Message[200];            MessageReference[] refs = new MessageReference[200];             //Send 150 np mesages      for (int i = 0; i < 150; i++)      {         msgs[i] = CoreMessageFactory.createCoreMessage(i, false, null);                  refs[i] = ms.reference(msgs[i]);                         queue.handle(null, refs[i], null);                   refs[i].releaseMemoryReference();      }            //Send 50 p messages      for (int i = 150; i < 200; i++)      {         msgs[i] = CoreMessageFactory.createCoreMessage(i, true, null);                  refs[i] = ms.reference(msgs[i]);                         queue.handle(null, refs[i], null);                   refs[i].releaseMemoryReference();      }      List refIds = getReferenceIdsOrderedByPageOrd(queue.getChannelID());      assertEquals(100, refIds.size());                                                      assertEquals(100, queue.memoryRefCount());            assertEquals(0, queue.downCacheCount());            assertTrue(queue.isPaging());                  assertEquals(0, queue.memoryDeliveryCount());            queue.removeAllReferences();            refIds = getReferenceIdsOrderedByPageOrd(queue.getChannelID());      assertEquals(0, refIds.size());            List msgIds = getMessageIds();      assertEquals(0, msgIds.size());                                                                        assertEquals(0, queue.memoryRefCount());            assertEquals(0, queue.downCacheCount());            assertFalse(queue.isPaging());                  assertEquals(0, queue.memoryDeliveryCount());            assertEquals(0, queue.messageCount());            assertEquals(0, LockMap.instance.getSize());   }