Package org.jboss.arquillian.container.spi

Examples of org.jboss.arquillian.container.spi.ContainerRegistry.create()


   public void shouldBeAbleToDefaultTargetToOnlyRegisteredContainer() throws Exception
   {
      String name = "some-name";
     
      ContainerRegistry registry = new LocalContainerRegistry(injector.get());
      registry.create(new ContainerDefImpl(ARQUILLIAN_XML).setContainerName(name), serviceLoader);
     
      Container container = registry.getContainer(TargetDescription.DEFAULT);
     
      Assert.assertEquals(
            "Verify that the only registered container is returned as default",
View Full Code Here


   public void shouldBeAbleToDefaultTargetToDefaultRegisteredContainer() throws Exception
   {
      String name = "some-name";
     
      ContainerRegistry registry = new LocalContainerRegistry(injector.get());
      registry.create(new ContainerDefImpl(ARQUILLIAN_XML).setContainerName("some-other-name"), serviceLoader);
      registry.create(new ContainerDefImpl(ARQUILLIAN_XML).setContainerName(name).setDefault(), serviceLoader);
     
      Container container = registry.getContainer(TargetDescription.DEFAULT);
     
      Assert.assertEquals(
View Full Code Here

   {
      String name = "some-name";
     
      ContainerRegistry registry = new LocalContainerRegistry(injector.get());
      registry.create(new ContainerDefImpl(ARQUILLIAN_XML).setContainerName("some-other-name"), serviceLoader);
      registry.create(new ContainerDefImpl(ARQUILLIAN_XML).setContainerName(name).setDefault(), serviceLoader);
     
      Container container = registry.getContainer(TargetDescription.DEFAULT);
     
      Assert.assertEquals(
            "Verify that the default registered container is returned as default",
View Full Code Here

   {
      String name = "some-name";
      String prop = "prop-value";

      ContainerRegistry registry = new LocalContainerRegistry(injector.get());
      registry.create(new ContainerDefImpl(ARQUILLIAN_XML).setContainerName(name)
                           .property("property", prop), serviceLoader);

      Container container = registry.getContainer(new TargetDescription(name));

      Assert.assertEquals(
View Full Code Here

      String name = "some-name";
      String prop = "prop-value";

      ContainerRegistry registry = new LocalContainerRegistry(injector.get());
      registry.create(new ContainerDefImpl(ARQUILLIAN_XML).setContainerName(name)
                           .property("property", prop), serviceLoader);

      Container container = registry.getContainer(new TargetDescription(name));

      Assert.assertEquals(
View Full Code Here

   public void shouldBeAbleToSpecifyTarget() throws Exception
   {
      String name = "some-name";
     
      ContainerRegistry registry = new LocalContainerRegistry(injector.get());
      registry.create(new ContainerDefImpl(ARQUILLIAN_XML).setContainerName("other-name"), serviceLoader);
      registry.create(new ContainerDefImpl(ARQUILLIAN_XML).setContainerName(name), serviceLoader);
     
      Container container = registry.getContainer(new TargetDescription(name));
     
      Assert.assertEquals(
View Full Code Here

   {
      String name = "some-name";
     
      ContainerRegistry registry = new LocalContainerRegistry(injector.get());
      registry.create(new ContainerDefImpl(ARQUILLIAN_XML).setContainerName("other-name"), serviceLoader);
      registry.create(new ContainerDefImpl(ARQUILLIAN_XML).setContainerName(name), serviceLoader);
     
      Container container = registry.getContainer(new TargetDescription(name));
     
      Assert.assertEquals(
            "Verify that the specific registered container is returned",
View Full Code Here

   public void shouldBeAbleToGetContainerByName() throws Exception
   {
      String name = "some-name";

      ContainerRegistry registry = new LocalContainerRegistry(injector.get());
      registry.create(new ContainerDefImpl(ARQUILLIAN_XML).setContainerName("other-name"), serviceLoader);
      registry.create(new ContainerDefImpl(ARQUILLIAN_XML).setContainerName(name), serviceLoader);
     
      Container container = registry.getContainer(name);

      Assert.assertEquals(
View Full Code Here

   {
      String name = "some-name";

      ContainerRegistry registry = new LocalContainerRegistry(injector.get());
      registry.create(new ContainerDefImpl(ARQUILLIAN_XML).setContainerName("other-name"), serviceLoader);
      registry.create(new ContainerDefImpl(ARQUILLIAN_XML).setContainerName(name), serviceLoader);
     
      Container container = registry.getContainer(name);

      Assert.assertEquals(
            "Verify that the specific registered container is returned",
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.