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


Java Deployment类代码示例

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


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

示例1: deploy

import org.jboss.arquillian.container.test.api.Deployment; //导入依赖的package包/类
@Deployment
public static WebArchive deploy() {
    JavaArchive testJar = ShrinkWrap
            .create(JavaArchive.class, "configProviderTest.jar")
            .addPackage(AbstractTest.class.getPackage())
            .addClass(ConfigProviderTest.class)
            .addAsManifestResource(EmptyAsset.INSTANCE, "beans.xml")
            .as(JavaArchive.class);

    AbstractTest.addFile(testJar, "META-INF/javaconfig.properties");

    WebArchive war = ShrinkWrap
            .create(WebArchive.class, "configProviderTest.war")
            .addAsLibrary(testJar);
    return war;
}
 
开发者ID:eclipse,项目名称:ConfigJSR,代码行数:17,代码来源:ConfigProviderTest.java

示例2: deployAnotherApp

import org.jboss.arquillian.container.test.api.Deployment; //导入依赖的package包/类
@Deployment
public static WebArchive deployAnotherApp() {
    JavaArchive testJar = ShrinkWrap
        .create(JavaArchive.class, "ftConfig.jar")
        .addClasses(BeanWithRetry.class)
        .addAsManifestResource(new StringAsset(
            "org.eclipse.microprofile.fault.tolerance.tck.config.BeanWithRetry/Retry/maxRetries=5" +
                "\nRetry/maxRetries=7"), "microprofile-config.properties")
        .addAsManifestResource(EmptyAsset.INSTANCE, "beans.xml")
        .as(JavaArchive.class);

    WebArchive war = ShrinkWrap
        .create(WebArchive.class, "ftConfigTest.war")
        .addAsLibrary(testJar);
    return war;
}
 
开发者ID:eclipse,项目名称:microprofile-fault-tolerance,代码行数:17,代码来源:ConfigPropertyGlobalVsClassTest.java

示例3: deploy

import org.jboss.arquillian.container.test.api.Deployment; //导入依赖的package包/类
@Deployment
public static WebArchive deploy() {
    JavaArchive testJar = ShrinkWrap.create(JavaArchive.class, "ftCircuitBreaker.jar")
                    .addClasses(CircuitBreakerClientWithDelay.class,
                                    CircuitBreakerClientNoDelay.class,
                                    CircuitBreakerClassLevelClientWithDelay.class,
                                    CircuitBreakerClientDefaultSuccessThreshold.class,
                                    CircuitBreakerClientHigherSuccessThreshold.class,
                                    Misc.class)
                    .addAsManifestResource(EmptyAsset.INSTANCE, "beans.xml")
                    .as(JavaArchive.class);

    WebArchive war = ShrinkWrap.create(WebArchive.class, "ftCircuitBreaker.war")
                    .addAsLibrary(testJar);
    return war;
}
 
开发者ID:eclipse,项目名称:microprofile-fault-tolerance,代码行数:17,代码来源:CircuitBreakerTest.java

示例4: deploy

import org.jboss.arquillian.container.test.api.Deployment; //导入依赖的package包/类
@Deployment
public static WebArchive deploy() {
    JavaArchive testJar = ShrinkWrap
            .create(JavaArchive.class, "arrayConverterTest.jar")
            .addPackage(PizzaConverter.class.getPackage())
            .addClass(ArrayConverterTest.class)
            .addAsManifestResource(EmptyAsset.INSTANCE, "beans.xml")
            .addAsServiceProvider(Converter.class, PizzaConverter.class)
            .as(JavaArchive.class);

    addFile(testJar, "META-INF/javaconfig.properties");

    WebArchive war = ShrinkWrap
            .create(WebArchive.class, "arrayConverterTest.war")
            .addAsLibrary(testJar);
    return war;
}
 
开发者ID:eclipse,项目名称:ConfigJSR,代码行数:18,代码来源:ArrayConverterTest.java

示例5: deployAnotherApp

import org.jboss.arquillian.container.test.api.Deployment; //导入依赖的package包/类
@Deployment
public static WebArchive deployAnotherApp() {
    JavaArchive testJar = ShrinkWrap
        .create(JavaArchive.class, "ftConfig.jar")
        .addClasses(BeanWithRetry.class)
        .addAsManifestResource(new StringAsset(
                                   "org.eclipse.microprofile.fault.tolerance.tck.config.BeanWithRetry/Retry/maxRetries=5" +
                                       "\norg.eclipse.microprofile.fault.tolerance.tck.config.BeanWithRetry/triggerException/Retry/maxRetries=6"),
                               "microprofile-config.properties")
        .addAsManifestResource(EmptyAsset.INSTANCE, "beans.xml")
        .as(JavaArchive.class);

    WebArchive war = ShrinkWrap
        .create(WebArchive.class, "ftConfigTest.war")
        .addAsLibrary(testJar);
    return war;
}
 
开发者ID:eclipse,项目名称:microprofile-fault-tolerance,代码行数:18,代码来源:ConfigPropertyOnClassAndMethodTest.java

示例6: deployment

import org.jboss.arquillian.container.test.api.Deployment; //导入依赖的package包/类
@Deployment
public static WebArchive deployment() {
  PomEquippedResolveStage pom = Maven.resolver().loadPomFromFile("pom.xml");

  String[] libraries = new String[]{"de.undercouch:actson", "commons-io:commons-io"};

  return ShrinkWrap.create(WebArchive.class)
    .addPackage(SingleItemPublisher.class.getPackage())
    .addPackage(Customer.class.getPackage())
    .addPackage(JsonConverter.class.getPackage())
    .addPackage(PublisherMessageBodyReader.class.getPackage())
    .addAsLibraries(pom.resolve(libraries).withTransitivity().asFile())
    .setWebXML(new StringAsset(Descriptors.create(WebAppDescriptor.class)
      .addDefaultNamespaces()
      .version("3.1")
      .exportAsString()));
}
 
开发者ID:openknowledge,项目名称:reactive-jax-rs,代码行数:18,代码来源:CustomerBatchUploadTest.java

示例7: createDeployment

import org.jboss.arquillian.container.test.api.Deployment; //导入依赖的package包/类
@Deployment
public static JavaArchive createDeployment() {

    return ShrinkWrap.create(JavaArchive.class)
            .addClasses(A.class, Data.class)
            //besides the classes, also need to add resources
            .addAsResource("META-INF/persistence.xml");
}
 
开发者ID:arcuri82,项目名称:testing_security_development_enterprise_systems,代码行数:9,代码来源:SingletonTest.java

示例8: createTestArchive

import org.jboss.arquillian.container.test.api.Deployment; //导入依赖的package包/类
@Deployment
static Archive<?> createTestArchive() {
    return ShrinkWrap.create(JavaArchive.class)
            // Test bean
            .addClasses(MultipleMetricsConstructorBean.class, MetricsUtil.class)
            // Bean archive deployment descriptor
            .addAsManifestResource(EmptyAsset.INSTANCE, "beans.xml");
}
 
开发者ID:eclipse,项目名称:microprofile-metrics,代码行数:9,代码来源:MultipleMetricsConstructorBeanTest.java

示例9: createTestArchive

import org.jboss.arquillian.container.test.api.Deployment; //导入依赖的package包/类
@Deployment
public static Archive<?> createTestArchive() {
    return ArquillianDeployment.baseDeployment()
            .addClasses(
                    CacheDataBuilder.class,
                    CacheResources.class,
                    BeerCache.class,
                    CacheBeerService.class);
}
 
开发者ID:briantward,项目名称:jdg-lab,代码行数:10,代码来源:SearchArquillianTest.java

示例10: deployment

import org.jboss.arquillian.container.test.api.Deployment; //导入依赖的package包/类
@Deployment
public static Archive deployment() {
    return ShrinkWrap.create(WebArchive.class)
            .addClasses(CDIPlainInjectionTest.class, SimpleValuesBean.class, DynamicValuesBean.class,
                    AdditionalMatchers.class, TestConfigSource.class, DefaultPropertyBean.class)
            .addAsServiceProvider(ConfigSource.class, TestConfigSource.class)
            .addAsWebInfResource(EmptyAsset.INSTANCE, "beans.xml");
}
 
开发者ID:eclipse,项目名称:ConfigJSR,代码行数:9,代码来源:CDIPlainInjectionTest.java

示例11: createTestArchive

import org.jboss.arquillian.container.test.api.Deployment; //导入依赖的package包/类
@Deployment
static Archive<?> createTestArchive() {
    return ShrinkWrap.create(JavaArchive.class)
        // Test bean
        .addClass(MeteredConstructorBean.class)
        // Bean archive deployment descriptor
        .addAsManifestResource(EmptyAsset.INSTANCE, "beans.xml");
}
 
开发者ID:eclipse,项目名称:microprofile-metrics,代码行数:9,代码来源:MeteredConstructorBeanTest.java

示例12: createTestArchive

import org.jboss.arquillian.container.test.api.Deployment; //导入依赖的package包/类
@Deployment
public static Archive<?> createTestArchive() {
    return ArquillianDeployment.baseDeployment()
            .addClasses(DatabaseBeerService.class, DatabaseDataBuilder.class)
            .addAsResource( "META-INF/persistence.xml")
            .addAsResource("import.sql")
            .addAsWebInfResource("test-ds.xml");
}
 
开发者ID:briantward,项目名称:jdg-lab,代码行数:9,代码来源:DatabaseDataArquillianTest.java

示例13: createDeployment

import org.jboss.arquillian.container.test.api.Deployment; //导入依赖的package包/类
@Deployment
public static WebArchive createDeployment() {
    StringAsset mpConfig = new StringAsset(JsonPClient.class.getName() + "/mp-rest/url=" + getStringURL());
    return ShrinkWrap.create(WebArchive.class)
        .addClass(JsonPClient.class)
        .addAsWebInfResource(EmptyAsset.INSTANCE, "beans.xml")
        .addAsWebInfResource(mpConfig, "classes/META-INF/microprofile-config.properties");
}
 
开发者ID:eclipse,项目名称:microprofile-rest-client,代码行数:9,代码来源:InvokeWithJsonPProviderTest.java

示例14: createWebDeployment

import org.jboss.arquillian.container.test.api.Deployment; //导入依赖的package包/类
@Deployment
public static WebArchive createWebDeployment() {
	final WebArchive war = create(WebArchive.class, "component-test.war");
	war.addPackage(MyComponent.class.getPackage());
	war.addAsWebInfResource(INSTANCE, "beans.xml");
	war.addAsWebInfResource(new FileAsset(new File("src/test/resources/web.xml")), "web.xml");
	return war;
}
 
开发者ID:PacktPublishing,项目名称:Mastering-Java-EE-Development-with-WildFly,代码行数:9,代码来源:ComponentTestCase.java

示例15: createWebDeployment

import org.jboss.arquillian.container.test.api.Deployment; //导入依赖的package包/类
@Deployment
public static WebArchive createWebDeployment() {
	final WebArchive war = create(WebArchive.class, "other-test.war");
	war.addPackage(HttpApplication.class.getPackage());
	war.addAsWebInfResource(INSTANCE, "beans.xml");
	return war;
}
 
开发者ID:PacktPublishing,项目名称:Mastering-Java-EE-Development-with-WildFly,代码行数:8,代码来源:OtherTestCase.java


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