Search in sources :

Example 1 with IbisTester

use of nl.nn.adapterframework.extensions.test.IbisTester in project iaf by ibissource.

the class ShowConfigurationStatusTest method initTest.

@BeforeClass
public static void initTest() throws ConfigurationException, TransformerConfigurationException, IOException {
    URL adaptersUrl = ClassUtils.getResourceURL(ShowConfigurationStatusTest.class, adapters_xslt);
    if (adaptersUrl == null) {
        throw new ConfigurationException("cannot find resource [" + adapters_xslt + "]");
    }
    adaptersTransformer = XmlUtils.createTransformer(adaptersUrl, true);
    ibisTester = new IbisTester();
    System.setProperty("HelloWorld.job.active", "false");
    System.setProperty("junit.active", "true");
    System.setProperty("configurations.names", "${instance.name},NotExistingConfig");
    ibisTester.initTest();
    if (ibisTester.testStartAdapters()) {
        ibisContext = ibisTester.getIbisContext();
    }
    assertEquals(true, ibisContext != null);
}
Also used : TransformerConfigurationException(javax.xml.transform.TransformerConfigurationException) ConfigurationException(nl.nn.adapterframework.configuration.ConfigurationException) IbisTester(nl.nn.adapterframework.extensions.test.IbisTester) URL(java.net.URL) BeforeClass(org.junit.BeforeClass)

Aggregations

URL (java.net.URL)1 TransformerConfigurationException (javax.xml.transform.TransformerConfigurationException)1 ConfigurationException (nl.nn.adapterframework.configuration.ConfigurationException)1 IbisTester (nl.nn.adapterframework.extensions.test.IbisTester)1 BeforeClass (org.junit.BeforeClass)1