105106107108109110111112113114115
ClusteredQueue queue5 = new DummyClusteredQueue(false, "queue5", 0); queues.add(queue5); ClusteredQueue chosen = policy.chooseQueue(queues); assertTrue(chosen == queue4); } public void test2() throws Exception
136137138139140141142143144145146
ClusteredQueue queue5 = new DummyClusteredQueue(false, "queue5", 0); queues.add(queue5); ClusteredQueue chosen = policy.chooseQueue(queues); assertNull(chosen); } public void test3() throws Exception
151152153154155156157158159160161
ClusteredQueue queue1 = new DummyClusteredQueue(true, "queue1", 0); queues.add(queue1); ClusteredQueue chosen = policy.chooseQueue(queues); assertNull(chosen); } public void test4() throws Exception
162163164165166167168169170171172
{ MessagePullPolicy policy = new DefaultMessagePullPolicy(); List queues = new ArrayList(); ClusteredQueue chosen = policy.chooseQueue(queues); assertNull(chosen); } // Private -------------------------------------------------------