@Test
 public void testQueueConfig() {
   QueueConfig testQConfig = config.getQueueConfig("testQ");
   assertNotNull(testQConfig);
   assertEquals("testQ", testQConfig.getName());
   assertEquals(1000, testQConfig.getMaxSize());
   QueueConfig qConfig = config.getQueueConfig("q");
   assertNotNull(qConfig);
   assertEquals("q", qConfig.getName());
   assertEquals(2500, qConfig.getMaxSize());
   assertEquals(1, testQConfig.getItemListenerConfigs().size());
   ItemListenerConfig listenerConfig = testQConfig.getItemListenerConfigs().get(0);
   assertEquals("com.hazelcast.spring.DummyItemListener", listenerConfig.getClassName());
   assertTrue(listenerConfig.isIncludeValue());
 }
Esempio n. 2
0
 public Config addQueueConfig(QueueConfig queueConfig) {
   queueConfigs.put(queueConfig.getName(), queueConfig);
   return this;
 }
Esempio n. 3
0
 /** Test method for {@link com.hazelcast.config.QueueConfig#setName(java.lang.String)}. */
 @Test
 public void testSetName() {
   String name = "a test name";
   QueueConfig queueConfig = new QueueConfig().setName(name);
   assertEquals(name, queueConfig.getName());
 }
Esempio n. 4
0
 /** Test method for {@link com.hazelcast.config.QueueConfig#getName()}. */
 @Test
 public void testGetName() {
   QueueConfig queueConfig = new QueueConfig();
   assertNull(null, queueConfig.getName());
 }