The build script fails to generate plexus/components.xml file.
--------------------------------------------------------------
Key: MANT-67
URL: https://jira.codehaus.org/browse/MANT-67
Project: Maven 2.x Ant Plugin
Issue Type: Bug
Affects Versions: 2.3
Environment: Gentoo/Linux, maven-2.2.1, maven-ant-plugin 2.3
Reporter: Kasun Gajasinghe
The generated build script by maven-ant-plugin fails to generate the
components.xml file when run. It compiles successfully, and builds the jar
(without META-INF/plexus/components.xml file). But it fails the tests saying
"Component descriptor cannot be found in the component repository"
Reproduce steps -
* Get a project that _generates_ components.xml file. One need of mine was
maven-runtime at
https://svn.apache.org/repos/asf/maven/shared/tags/maven-shared-components-15/maven-runtime
* run mvn ant:ant
* run ant (I ran ant -Dmaven.settings.offline=true. it doesn't matter anyway)
Here's the error log.
Buildfile: build.xml
test-offline:
get-deps:
compile:
[mkdir] Created dir: /home/me/maven-runtime/target/classes
[javac] Compiling 9 source files to /home/me/maven-runtime/target/classes
compile-tests:
[mkdir] Created dir: /home/me/maven-runtime/target/test-classes
[javac] Compiling 5 source files to
/home/me/maven-runtime/target/test-classes
[copy] Copying 13 files to /home/me/maven-runtime/target/test-classes
test-junit-present:
test-junit-status:
junit-missing:
test:
[mkdir] Created dir: /home/me/maven-runtime/target/test-reports
[junit] Running org.apache.maven.shared.runtime.DefaultMavenRuntimeTest
[junit] Testsuite: org.apache.maven.shared.runtime.DefaultMavenRuntimeTest
[junit] Tests run: 1, Failures: 0, Errors: 1, Time elapsed: 0.597 sec
[junit] Tests run: 1, Failures: 0, Errors: 1, Time elapsed: 0.597 sec
[junit]
[junit] Testcase: testGetProjectPropertiesWithFileUrl took 0.259 sec
[junit] Caused an ERROR
[junit] Component descriptor cannot be found in the component repository:
org.apache.maven.shared.runtime.MavenRuntime.
[junit]
org.codehaus.plexus.component.repository.exception.ComponentLookupException:
Component descriptor cannot be found in the component repository:
org.apache.maven.shared.runtime.MavenRuntime.
[junit] at
org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:323)
[junit] at
org.codehaus.plexus.PlexusTestCase.lookup(PlexusTestCase.java:216)
[junit] at
org.apache.maven.shared.runtime.DefaultMavenRuntimeTest.setUp(DefaultMavenRuntimeTest.java:68)
[junit]
BUILD FAILED
/home/me/maven-runtime/maven-build.xml:155: Test
org.apache.maven.shared.runtime.DefaultMavenRuntimeTest failed
Total time: 3 seconds
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira