当前位置: 首页>>代码示例>>Java>>正文


Java CamelTestSupport类代码示例

本文整理汇总了Java中org.apache.camel.test.junit4.CamelTestSupport的典型用法代码示例。如果您正苦于以下问题:Java CamelTestSupport类的具体用法?Java CamelTestSupport怎么用?Java CamelTestSupport使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


CamelTestSupport类属于org.apache.camel.test.junit4包,在下文中一共展示了CamelTestSupport类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: createSpringCamelContext

import org.apache.camel.test.junit4.CamelTestSupport; //导入依赖的package包/类
public static CamelContext createSpringCamelContext(CamelTestSupport test, String classpathUri) throws Exception {
    test.setUseRouteBuilder(false);

    final AbstractXmlApplicationContext applicationContext = new ClassPathXmlApplicationContext(classpathUri);
    test.setCamelContextService(new Service() {
        public void start() throws Exception {
            applicationContext.start();
        }

        public void stop() throws Exception {
            applicationContext.stop();
        }
    });

    return SpringCamelContext.springCamelContext(applicationContext);
}
 
开发者ID:jboss-fuse,项目名称:camel-c24io,代码行数:17,代码来源:SpringTestHelper.java

示例2: tearDownAfterClass

import org.apache.camel.test.junit4.CamelTestSupport; //导入依赖的package包/类
@AfterClass
public static void tearDownAfterClass() throws Exception {
    if (threadLocalBundleContext.get() != null) {
        CamelBlueprintHelper.disposeBundleContext(threadLocalBundleContext.get());
        threadLocalBundleContext.remove();
    }
    CamelTestSupport.tearDownAfterClass();
}
 
开发者ID:HydAu,项目名称:Camel,代码行数:9,代码来源:CamelBlueprintTestSupport.java

示例3: tearDownAfterClass

import org.apache.camel.test.junit4.CamelTestSupport; //导入依赖的package包/类
@AfterClass
public static void tearDownAfterClass() throws Exception {
    CamelTestSupport.tearDownAfterClass();

    // write the refresh token back to target/test-classes/test-options.properties
    final URL resource = AbstractBoxTestSupport.class.getResource(TEST_OPTIONS_PROPERTIES);
    final FileOutputStream out = new FileOutputStream(new File(resource.getPath()));
    propertyText = propertyText.replaceAll(REFRESH_TOKEN_PROPERTY + "=\\S*",
            REFRESH_TOKEN_PROPERTY + "=" + refreshToken);
    out.write(propertyText.getBytes("UTF-8"));
    out.close();
}
 
开发者ID:HydAu,项目名称:Camel,代码行数:13,代码来源:AbstractBoxTestSupport.java

示例4: tearDownAfterClass

import org.apache.camel.test.junit4.CamelTestSupport; //导入依赖的package包/类
@AfterClass
public static void tearDownAfterClass() throws Exception {
    CamelTestSupport.tearDownAfterClass();
    // stop the proxy server after component
    LOG.info("Stopping proxy server...");
    server.stop();
    LOG.info("Stopped proxy server");
}
 
开发者ID:HydAu,项目名称:Camel,代码行数:9,代码来源:HttpProxyIntegrationTest.java

示例5: tearDownAfterClass

import org.apache.camel.test.junit4.CamelTestSupport; //导入依赖的package包/类
@AfterClass
public static void tearDownAfterClass() throws Exception {
    CamelTestSupport.tearDownAfterClass();
}
 
开发者ID:HydAu,项目名称:Camel,代码行数:5,代码来源:AbstractGoogleDriveTestSupport.java


注:本文中的org.apache.camel.test.junit4.CamelTestSupport类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。