[
http://jira.codehaus.org/browse/MNBMODULE-131?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=253417#action_253417
]
Jesse Glick commented on MNBMODULE-131:
---------------------------------------
After revision 13486 no exceptions will be thrown, but {{cluster-app}} will not
package up the reactor dependencies. The problem is that {{cluster-app}} is in
the {{process-resources}} phase, whereas it needs for the {{nbm-application}}'s
{{nbm}}-type dependencies to have gotten to the {{package}} phase. The quick
fix allows {{mvn test}} to proceed, but functional tests in the app project
will produce errors if the reactor has not previously been packaged. Moving
{{cluster-app}} to the {{package}} phase will not help this issue because tests
are run before that phase, since Maven expects that you can test unpackaged
products. Perhaps functional tests should be in the {{integration-test}} phase?
> Exceptions trying to run tests on app project via reactor
> ---------------------------------------------------------
>
> Key: MNBMODULE-131
> URL: http://jira.codehaus.org/browse/MNBMODULE-131
> Project: Maven NetBeans Module Plugin
> Issue Type: Bug
> Affects Versions: 3.4
> Reporter: Jesse Glick
> Assignee: Jesse Glick
>
> Open https://netbeans.org/bugzilla/attachment.cgi?id=102893 and clean and
> test. Fails with exception:
> {noformat}
> Failed to execute goal org.codehaus.mojo:nbm-maven-plugin:3.4:cluster-app
> (default-cluster-app)
> on project application: Could not open .../branding/target/classes: error in
> opening zip file
> {noformat}
> Caused by reactor artifact not being a JAR. The immediate exception is fixed
> by:
> {noformat}
> --- src/main/java/org/codehaus/mojo/nbm/AbstractNbmMojo.java (revision 13033)
> +++ src/main/java/org/codehaus/mojo/nbm/AbstractNbmMojo.java (working copy)
> @@ -409,7 +409,7 @@
> // list of dependencies (as "nbm-file") or not..
> // that would be a timesaver
> ExamineManifest mnf = new ExamineManifest( getLog() );
> - mnf.setJarFile( art.getFile() );
> + mnf.setArtifactFile( art.getFile() );
> mnf.checkFile();
> if ( mnf.isNetbeansModule() )
> {
> {noformat}
> That still leaves:
> {noformat}
> java.util.zip.ZipException: error in opening zip file
> at java.util.zip.ZipFile.open(Native Method)
> at java.util.zip.ZipFile.<init>(ZipFile.java:127)
> at java.util.jar.JarFile.<init>(JarFile.java:135)
> at java.util.jar.JarFile.<init>(JarFile.java:99)
> at
> org.codehaus.mojo.nbm.CreateClusterAppMojo.execute(CreateClusterAppMojo.java:185)
> {noformat}
> Workaround is to {{test}} the app project directly, rather than through the
> reactor.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email