Examples of StringAsset


Examples of org.jboss.shrinkwrap.api.asset.StringAsset

   public static WebArchive getDeployment()
   {
      WebArchive deployment = RewriteTest
               .getDeployment()
               .addPackages(true, ServletRoot.class.getPackage())
               .addAsWebResource(new StringAsset("lowercase"), "index.html")
               .addAsWebResource(new StringAsset("zip me to gzip please and make it zippy"), "gzip.html")
               .addAsServiceProvider(ConfigurationProvider.class, WrappedResponseStreamTestProvider.class);
      return deployment;
   }
View Full Code Here

Examples of org.jboss.shrinkwrap.api.asset.StringAsset

   public static WebArchive getDeployment()
   {
      WebArchive deployment = RewriteTest
               .getDeployment()
               .addPackages(true, ServletRoot.class.getPackage())
               .addAsWebResource(new StringAsset("UPPERCASE"), "index.html")
               .addAsWebResource(new StringAsset("UPPERCASE"), "unbuffered.html")
               .addAsWebResource(new StringAsset("UPPERCASE"), "forward.html")
               .addAsServiceProvider(ConfigurationProvider.class, ResponseContentInterceptorTestProvider.class);
      return deployment;
   }
View Full Code Here

Examples of org.jboss.shrinkwrap.api.asset.StringAsset

        + "</default>"
        + "<namedCache name=\"ENTITIES\" />"
        + "<namedCache name=\"ASSOCIATIONS\" />"
        + "<namedCache name=\"IDENTIFIERS\" />"
      + "</infinispan>";
    return new StringAsset( infinispanXml );
  }
View Full Code Here

Examples of org.jboss.shrinkwrap.api.asset.StringAsset

    }

    public Builder persistenceXml(PersistenceDescriptor descriptor) {
      resourceLocal = descriptor.getOrCreatePersistenceUnit().getTransactionType() == PersistenceUnitTransactionType._RESOURCE_LOCAL;
      String persistenceXml = descriptor.exportAsString();
      archive.addAsResource( new StringAsset( persistenceXml ), "META-INF/persistence.xml" );
      return this;
    }
View Full Code Here

Examples of org.jboss.shrinkwrap.api.asset.StringAsset

    private static Asset manifest(String dependencies) {
      String manifest = Descriptors.create( ManifestDescriptor.class )
          .attribute( "Dependencies", dependencies )
          .exportAsString();
      return new StringAsset( manifest );
    }
View Full Code Here

Examples of org.jboss.shrinkwrap.api.asset.StringAsset

   @Deployment(testable = false)
   public static WebArchive getDeployment()
   {
      return RewriteTest.getDeployment()
               .addClass(ResourceTestProvider.class)
               .addAsWebResource(new StringAsset("some content"), "exists.txt")
               .addAsWebResource(new StringAsset("some content"), "file.bah")
               .addAsServiceProvider(ConfigurationProvider.class, ResourceTestProvider.class);
   }
View Full Code Here

Examples of org.jboss.shrinkwrap.api.asset.StringAsset

   }

   public static WebArchive getDeploymentWithCDI()
   {
      WebArchive archive = getDeployment();
      archive.addAsWebInfResource(new StringAsset("<beans/>"), "beans.xml");
      return archive;
   }
View Full Code Here

Examples of org.jboss.shrinkwrap.api.asset.StringAsset

   }

   public static WebArchive getDeploymentWithFacesAndCDI()
   {
      WebArchive archive = getDeployment();
      archive.addAsWebInfResource(new StringAsset("<beans/>"), "beans.xml");
      archive.addAsWebInfResource(new StringAsset("<faces-config version=\"2.0\"/>"), "faces-config.xml");
      return archive;
   }
View Full Code Here

Examples of org.jboss.shrinkwrap.api.asset.StringAsset

      if (isJetty()) {

         /*
         * Set the EL implementation
         */
         archive.add(new StringAsset("com.sun.el.ExpressionFactoryImpl"),
                  "/WEB-INF/classes/META-INF/services/javax.el.ExpressionFactory");

         /*
         * Set up container configuration
         */
 
View Full Code Here

Examples of org.jboss.shrinkwrap.api.asset.StringAsset

         if (isOWB()) {
            archive.addAsManifestResource("tomcat-owb-web-fragment.xml", "web-fragment.xml");
         }
      }

      return archive.addAsResource(new StringAsset("placeholder"), "README");
   }
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.