Search in sources :

Example 66 with KeyValuePair

use of com.adaptris.util.KeyValuePair in project interlok by adaptris.

the class SimpleFactoryConfigurationTest method testApplyTopicConnectionFactory_NonBoolean.

@Test
public void testApplyTopicConnectionFactory_NonBoolean() throws Exception {
    SimpleFactoryConfiguration extras = create(new KeyValuePair(SOME_BOOLEAN_VALUE, "fred"));
    DummyConnectionFactory mycf = new DummyConnectionFactory();
    extras.applyConfiguration(mycf);
    doBaseAssertions(mycf);
}
Also used : KeyValuePair(com.adaptris.util.KeyValuePair) Test(org.junit.Test)

Example 67 with KeyValuePair

use of com.adaptris.util.KeyValuePair in project interlok by adaptris.

the class SimpleFactoryConfigurationTest method createBase.

private SimpleFactoryConfiguration createBase() {
    SimpleFactoryConfiguration result = new SimpleFactoryConfiguration();
    KeyValuePairSet kvps = new KeyValuePairSet();
    kvps.add(new KeyValuePair(SOME_INT_VALUE, String.valueOf(INT_VALUE_1)));
    kvps.add(new KeyValuePair(SOME_LONG_VALUE, String.valueOf(LONG_VALUE_1)));
    kvps.add(new KeyValuePair(SOME_STRING_VALUE, SOME_STRING));
    kvps.add(new KeyValuePair(SOME_BOOLEAN_VALUE, Boolean.TRUE.toString()));
    kvps.add(new KeyValuePair(SOME_FLOAT_VALUE, String.valueOf(FLOAT_VALUE_1)));
    kvps.add(new KeyValuePair(SOME_DOUBLE_VALUE, String.valueOf(DOUBLE_VALUE_1)));
    kvps.add(new KeyValuePair(SOME_INTEGER_OBJ_VALUE, String.valueOf(INT_VALUE_1)));
    kvps.add(new KeyValuePair(SOME_LONG_OBJ_VALUE, String.valueOf(LONG_VALUE_1)));
    kvps.add(new KeyValuePair(SOME_DOUBLE_OBJ_VALUE, String.valueOf(DOUBLE_VALUE_1)));
    kvps.add(new KeyValuePair(SOME_FLOAT_OBJ_VALUE, String.valueOf(FLOAT_VALUE_1)));
    kvps.add(new KeyValuePair(SOME_BOOLEAN_OBJ_VALUE, Boolean.TRUE.toString()));
    result.setProperties(kvps);
    return result;
}
Also used : KeyValuePair(com.adaptris.util.KeyValuePair) KeyValuePairSet(com.adaptris.util.KeyValuePairSet)

Example 68 with KeyValuePair

use of com.adaptris.util.KeyValuePair in project interlok by adaptris.

the class SimpleFactoryConfigurationTest method testApplyQueueConnectionFactory_NonDouble.

@Test
public void testApplyQueueConnectionFactory_NonDouble() throws Exception {
    SimpleFactoryConfiguration extras = create(new KeyValuePair(SOME_DOUBLE_VALUE, "fred"));
    DummyConnectionFactory mycf = new DummyConnectionFactory();
    extras.applyConfiguration(mycf);
    doBaseAssertions(mycf);
}
Also used : KeyValuePair(com.adaptris.util.KeyValuePair) Test(org.junit.Test)

Example 69 with KeyValuePair

use of com.adaptris.util.KeyValuePair in project interlok by adaptris.

the class SimpleFactoryConfigurationTest method testApplyQueueConnectionFactory_NoSetter.

@Test
public void testApplyQueueConnectionFactory_NoSetter() throws Exception {
    SimpleFactoryConfiguration extras = create(new KeyValuePair("HelloThere", "fred"));
    DummyConnectionFactory mycf = new DummyConnectionFactory();
    extras.applyConfiguration(mycf);
    doBaseAssertions(mycf);
}
Also used : KeyValuePair(com.adaptris.util.KeyValuePair) Test(org.junit.Test)

Example 70 with KeyValuePair

use of com.adaptris.util.KeyValuePair in project interlok by adaptris.

the class SimpleFactoryConfigurationTest method testApplyTopicConnectionFactory_NonFloat.

@Test
public void testApplyTopicConnectionFactory_NonFloat() throws Exception {
    SimpleFactoryConfiguration extras = create(new KeyValuePair(SOME_FLOAT_VALUE, "fred"));
    DummyConnectionFactory mycf = new DummyConnectionFactory();
    extras.applyConfiguration(mycf);
    doBaseAssertions(mycf);
}
Also used : KeyValuePair(com.adaptris.util.KeyValuePair) Test(org.junit.Test)

Aggregations

KeyValuePair (com.adaptris.util.KeyValuePair)143 Test (org.junit.Test)79 KeyValuePairSet (com.adaptris.util.KeyValuePairSet)55 AdaptrisMessage (com.adaptris.core.AdaptrisMessage)26 KeyValuePairList (com.adaptris.util.KeyValuePairList)12 StandardJndiImplementation (com.adaptris.core.jms.jndi.StandardJndiImplementation)11 StandaloneProducer (com.adaptris.core.StandaloneProducer)10 Channel (com.adaptris.core.Channel)9 MockMessageProducer (com.adaptris.core.stubs.MockMessageProducer)9 TimeInterval (com.adaptris.util.TimeInterval)9 ServiceException (com.adaptris.core.ServiceException)7 JmsConnection (com.adaptris.core.jms.JmsConnection)6 ArrayList (java.util.ArrayList)6 CoreException (com.adaptris.core.CoreException)5 StandardWorkflow (com.adaptris.core.StandardWorkflow)5 PasProducer (com.adaptris.core.jms.PasProducer)5 MetadataCollection (com.adaptris.core.MetadataCollection)4 MetadataElement (com.adaptris.core.MetadataElement)4 StandaloneConsumer (com.adaptris.core.StandaloneConsumer)4 StandaloneRequestor (com.adaptris.core.StandaloneRequestor)3