Package org.jboss.arquillian.container.test.spi

Examples of org.jboss.arquillian.container.test.spi.TestDeployment


        JavaArchive deploymentArchive = ShrinkWrap.create(JavaArchive.class, "deployment.jar");
        JavaArchive auxiliaryArchive = ShrinkWrap.create(JavaArchive.class, "auxiliary.jar");
        WebArchive protocolArchive = ShrinkWrap.create(WebArchive.class, "protocol.war");
        List<Archive<?>> auxiliaryArchives = new ArrayList<Archive<?>>();
        auxiliaryArchives.add(auxiliaryArchive);
        TestDeployment testDeployment = new TestDeployment(null, deploymentArchive,
                auxiliaryArchives);

        instance.process(testDeployment, protocolArchive);

        assertDependencies(protocolArchive, true);
View Full Code Here


        JavaArchive deploymentArchive = ShrinkWrap.create(JavaArchive.class, "deployment.jar");
        JavaArchive auxiliaryArchive = ShrinkWrap.create(JavaArchive.class, "auxiliary.jar");
        WebArchive protocolArchive = ShrinkWrap.create(WebArchive.class, "protocol.war");
        List<Archive<?>> auxiliaryArchives = new ArrayList<Archive<?>>();
        auxiliaryArchives.add(auxiliaryArchive);
        TestDeployment testDeployment = new TestDeployment(null, deploymentArchive,
                auxiliaryArchives);

        instance.process(testDeployment, protocolArchive);

        assertDependencies(protocolArchive, false);
View Full Code Here

        WebArchive deploymentArchive = ShrinkWrap.create(WebArchive.class, "deployment.war");
        JavaArchive auxiliaryArchive = ShrinkWrap.create(JavaArchive.class, "auxiliary.jar");
        WebArchive protocolArchive = ShrinkWrap.create(WebArchive.class, "protocol.war");
        List<Archive<?>> auxiliaryArchives = new ArrayList<Archive<?>>();
        auxiliaryArchives.add(auxiliaryArchive);
        TestDeployment testDeployment = new TestDeployment(null, deploymentArchive,
                auxiliaryArchives);

        instance.process(testDeployment, protocolArchive);

        assertDependencies(deploymentArchive, true);
View Full Code Here

        WebArchive deploymentArchive = ShrinkWrap.create(WebArchive.class, "deployment.war");
        JavaArchive auxiliaryArchive = ShrinkWrap.create(JavaArchive.class, "auxiliary.jar");
        WebArchive protocolArchive = ShrinkWrap.create(WebArchive.class, "protocol.war");
        List<Archive<?>> auxiliaryArchives = new ArrayList<Archive<?>>();
        auxiliaryArchives.add(auxiliaryArchive);
        TestDeployment testDeployment = new TestDeployment(null, deploymentArchive,
                auxiliaryArchives);

        instance.process(testDeployment, protocolArchive);

        assertDependencies(deploymentArchive, false);
View Full Code Here

             * ContianerBase implements it. Check the Archive Interface.. 
             */
         }
         description.setTestableArchive(
               packager.generateDeployment(
                     new TestDeployment(applicationArchive, auxiliaryArchives),
                     serviceLoader.get().all(ProtocolArchiveProcessor.class)));
      }
   }
View Full Code Here

   public void shouldNotAddBeansXMLIfArchivesAreEqual()
   {
      WebArchive protocol = ShrinkWrap.create(WebArchive.class);

      new BeansXMLProtocolProcessor().process(
            new TestDeployment(protocol, new ArrayList<Archive<?>>()), protocol);

      Assert.assertFalse(protocol.contains("WEB-INF/beans.xml"));
   }
View Full Code Here

            .addAsWebInfResource(new StringAsset(beansXmlContent), "beans.xml");

      WebArchive protocol = deployment.as(WebArchive.class);

      new BeansXMLProtocolProcessor().process(
            new TestDeployment(deployment, new ArrayList<Archive<?>>()), protocol);


      Assert.assertTrue(protocol.contains("WEB-INF/beans.xml"));

      byte[] buf = new byte[beansXmlContent.length()];
View Full Code Here

      WebArchive protocol = ShrinkWrap.create(WebArchive.class)
         .addAsWebInfResource(new StringAsset(beansXmlContent), "beans.xml");

      new BeansXMLProtocolProcessor().process(
            new TestDeployment(deployment, new ArrayList<Archive<?>>()), protocol);


      Assert.assertTrue(protocol.contains("WEB-INF/beans.xml"));

      byte[] buf = new byte[beansXmlContent.length()];
View Full Code Here

      JavaArchive protocol = ShrinkWrap.create(JavaArchive.class)
         .addAsManifestResource(new StringAsset(beansXmlContent), "beans.xml");

      new BeansXMLProtocolProcessor().process(
            new TestDeployment(deployment, new ArrayList<Archive<?>>()), protocol);


      Assert.assertTrue(protocol.contains("META-INF/beans.xml"));

      byte[] buf = new byte[beansXmlContent.length()];
View Full Code Here

   }

   public void runAndAsset(Archive<?> deployment, Archive<?> protocol, boolean shouldBeFound, String expectedLocation)
   {
      new BeansXMLProtocolProcessor().process(
            new TestDeployment(deployment, new ArrayList<Archive<?>>()), protocol);
     
      System.out.println(protocol.toString(true));
      Assert.assertEquals(
            "Verify beans.xml was " + (!shouldBeFound ? "not ":"") + "found in "+ expectedLocation,
            shouldBeFound, protocol.contains(expectedLocation));
View Full Code Here

TOP

Related Classes of org.jboss.arquillian.container.test.spi.TestDeployment

Copyright © 2018 www.massapicom. 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.