Package org.jboss.arquillian.container.spi.client.deployment

Examples of org.jboss.arquillian.container.spi.client.deployment.DeploymentScenario.deployment()


            .setTarget(TargetDescription.DEFAULT));
      scenario.addDeployment(
            new DeploymentDescription("B", ShrinkWrap.create(JavaArchive.class))
            .setTarget(TargetDescription.DEFAULT));
     
      Deployment defaultDeployment = scenario.deployment(DeploymentTargetDescription.DEFAULT);
     
      Assert.assertNull(defaultDeployment);
   }

   @Test
View Full Code Here


            .setTarget(TargetDescription.DEFAULT));
      scenario.addDeployment(
            new DeploymentDescription(DEFAULT_NAME, ShrinkWrap.create(JavaArchive.class))
            .setTarget(TargetDescription.DEFAULT));

      Deployment defaultDeployment = scenario.deployment(DeploymentTargetDescription.DEFAULT);
      Assert.assertNotNull(defaultDeployment);
      Assert.assertEquals(DEFAULT_NAME, defaultDeployment.getDescription().getName());
      Assert.assertTrue(defaultDeployment.getDescription().isArchiveDeployment());
   }
View Full Code Here

            .setTarget(TargetDescription.DEFAULT));
      scenario.addDeployment(
            new DeploymentDescription("B", Descriptors.create(BeansDescriptor.class))
            .setTarget(TargetDescription.DEFAULT));
     
      Deployment defaultDeployment = scenario.deployment(DeploymentTargetDescription.DEFAULT);
     
      Assert.assertNull(defaultDeployment);
   }

   @Test
View Full Code Here

      scenario.addDeployment(
            new DeploymentDescription("B", Descriptors.create(BeansDescriptor.class))
            .setTarget(TargetDescription.DEFAULT));


      DeploymentDescription deployment = scenario.deployment(new DeploymentTargetDescription("B")).getDescription();
     
      Assert.assertEquals("B", deployment.getName());
   }

   @Test
View Full Code Here

      scenario.addDeployment(
            new DeploymentDescription("B", Descriptors.create(BeansDescriptor.class))
            .setTarget(TargetDescription.DEFAULT));


      Deployment deployment = scenario.deployment(new DeploymentTargetDescription("C"));
     
      Assert.assertNull(deployment);
   }

   @Test
View Full Code Here

            .setTarget(TargetDescription.DEFAULT));
      scenario.addDeployment(
            new DeploymentDescription("A", Descriptors.create(BeansDescriptor.class))
            .setTarget(TargetDescription.DEFAULT));

      Deployment deployment = scenario.deployment(new DeploymentTargetDescription("A"));

      // will default to Archive
      Assert.assertEquals("A", deployment.getDescription().getName());
      Assert.assertTrue(deployment.getDescription().isArchiveDeployment());
   }
View Full Code Here

            .setTarget(TargetDescription.DEFAULT));
      scenario.addDeployment(
            new DeploymentDescription("A", ShrinkWrap.create(JavaArchive.class))
            .setTarget(TargetDescription.DEFAULT));

      Deployment deployment = scenario.deployment(new DeploymentTargetDescription("A"));

      // will default to Archive
      Assert.assertEquals("A", deployment.getDescription().getName());
      Assert.assertTrue(deployment.getDescription().isArchiveDeployment());
   }
View Full Code Here

            {
               throw new IllegalStateException("No " + DeploymentScenario.class.getSimpleName() + " found. " +
                     "Possible cause, @" + OperateOnDeployment.class.getSimpleName() + " is currently only supported on the client side. (@" + RunAsClient.class.getSimpleName() + ")");
            }
            OperateOnDeployment operatesOn = getOperatesOnDeployment(qualifiers);
            deployment = scenario.deployment(new DeploymentTargetDescription(operatesOn.value()));
            if(deployment == null)
            {
               throw new IllegalArgumentException(
                     "Could not operate on deployment (@" + OperateOnDeployment.class.getSimpleName() + "), " +
                     "no deployment found with name: " + operatesOn.value());
View Full Code Here

      DeploymentTargetDescription deploymentTarget = locateDeployment(method);
     
      ContainerRegistry containerRegistry = this.containerRegistry.get();
      DeploymentScenario deploymentScenario = this.deploymentScenario.get();
     
      Deployment deployment = deploymentScenario.deployment(deploymentTarget);
      if(deployment == null && deploymentTarget != DeploymentTargetDescription.DEFAULT)
      {
         // trying to operate on a non existing DeploymentTarget (which is not the DEFAULT)
         throw new IllegalStateException(
               "No deployment found in " + DeploymentScenario.class.getSimpleName() + " for defined target: " + deploymentTarget.getName() + ". " +
View Full Code Here

      if(registry == null)
      {
         throw new IllegalArgumentException("No container registry in context");
      }
     
      Deployment deployment = scenario.deployment(new DeploymentTargetDescription(name));
      if(deployment == null)
      {
         throw new IllegalArgumentException("No deployment in context found with name " + name);
      }
     
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.