Status: Resolved (View Workflow)
Affects Version/s: 1.1.2
Fix Version/s: 1.2.3
Environment:Win7x64, JDK1.7.0_17x32, JBOSS 7.1.3.Final, Arquillian 1.0.3Final, JUnit 4.11
Similar Issues:Show 10 results
SHRINKWRAP-44 Create WebArchive Descriptor SHRINKWRAP-241 remap targets for WebArchive add* methods SHRINKWRAP-318 Support adding web and WEB-INF resources with relative path of source SHRINKWRAP-266 Manifest container for WebArchive should be WEB-INF/classes/META-INF SHRINKWRAP-476 Cannot delete nested archive if added asLibrary SHRINKWRAP-119 Rename api Path and Paths SHRINKWRAP-16 Create a Path implementation SHRINKWRAP-103 Provide TestSuite coverage for Paths API SHRINKWRAP-325 ShrinkWrap.create(MavenImporter.class) that creates a WebArchive that adds all WEB-INF descriptors, classes, test classes and webapp resources too (not just dependencies and test dependencies) SHRINKWRAP-61 Switch order of "path" and "source" in Archive.merge
When creating a WebArchive via ShrinkWrap from a directory that is an exploded war file, paths inside this archive (generated with "arquillian.xml/arquillian/engine/property[deploymentExportPath]->target/deployments") generated invalid in some cases.
When investigating the sources I found "org.jboss.shrinkwrap.impl.base.importer.ExplodedImporterImpl.calculatePath(File root, File child)" uses "String.replaceFirst" to replace the occurance of rootPath in childPath to create a local war file path. My path of the directory that needs compression contains brackets, which (as well as other path elements, e.g. ".") are interpreted as regular expression tokens and therefore don't match.
The resulting archive can not be delpoyed in AS and tests can not be performed automatically.
The code to create the WebArchive looks like this: