use of org.wildfly.swarm.spi.api.JARArchive in project wildfly-swarm by wildfly-swarm.
the class RibbonArchiveTest method testAdvertiseExplicitName.
@Test
public void testAdvertiseExplicitName() {
JARArchive archive = ShrinkWrap.create(JARArchive.class, "myapp.war");
archive.as(RibbonArchive.class).advertise("myotherapp");
Asset asset = archive.get(RibbonArchive.REGISTRATION_CONF).getAsset();
assertThat(asset).isNotNull();
assertThat(asset).isInstanceOf(StringAsset.class);
assertThat(((StringAsset) asset).getSource().trim()).isEqualTo("myotherapp");
assertThat(archive.as(ServiceActivatorArchive.class).containsServiceActivator(RibbonArchiveImpl.SERVICE_ACTIVATOR_CLASS_NAME)).isTrue();
}
use of org.wildfly.swarm.spi.api.JARArchive in project wildfly-swarm by wildfly-swarm.
the class RibbonArchiveTest method testAdvertiseDefaultName.
@Test
public void testAdvertiseDefaultName() {
JARArchive archive = ShrinkWrap.create(JARArchive.class, "myapp.war");
archive.as(RibbonArchive.class).advertise();
Asset asset = archive.get(RibbonArchive.REGISTRATION_CONF).getAsset();
assertThat(asset).isNotNull();
assertThat(asset).isInstanceOf(StringAsset.class);
assertThat(((StringAsset) asset).getSource().trim()).isEqualTo("myapp");
assertThat(archive.as(ServiceActivatorArchive.class).containsServiceActivator(RibbonArchiveImpl.SERVICE_ACTIVATOR_CLASS_NAME)).isTrue();
}
use of org.wildfly.swarm.spi.api.JARArchive in project wildfly-swarm by wildfly-swarm.
the class JCAArquillianTest method createDeployment.
@Deployment(testable = false)
public static Archive createDeployment() {
JARArchive deployment = ShrinkWrap.create(JARArchive.class);
deployment.add(EmptyAsset.INSTANCE, "nothing");
return deployment;
}
use of org.wildfly.swarm.spi.api.JARArchive in project wildfly-swarm by wildfly-swarm.
the class MySQLJPAArquillianTest method createDeployment.
@Deployment(testable = true)
public static Archive createDeployment() {
JARArchive deployment = ShrinkWrap.create(JARArchive.class);
deployment.add(EmptyAsset.INSTANCE, "nothing");
return deployment;
}
use of org.wildfly.swarm.spi.api.JARArchive in project wildfly-swarm by wildfly-swarm.
the class JPAArquillianTest method createDeployment.
@Deployment(testable = true)
public static Archive createDeployment() {
JARArchive deployment = ShrinkWrap.create(JARArchive.class);
deployment.add(EmptyAsset.INSTANCE, "nothing");
return deployment;
}
Aggregations