Details
-
Type:
Task
-
Status:
Closed
-
Priority:
Blocker
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: Design, Patterns & Best Practices, Plugin API, Sites & Reporting
-
Labels:None
-
Number of attachments :5
-
- compiler-harness.patch
- 15/Mar/06 8:12 PM
- 15 kB
- Jesse McConnell
-
- jar-harness.patch
- 15/Mar/06 8:12 PM
- 4 kB
- Jesse McConnell
-
Hide
- maven-compiler-plugin.jar
- 10/Mar/06 12:54 PM
- 86 kB
- Jesse McConnell
-
- META-INF/MANIFEST.MF 0.1 kB
- maven-compiler-plugin/.classpath 1 kB
- maven-compiler-plugin/.pom.xml.swp 12 kB
- maven-compiler-plugin/.project 0.3 kB
- maven-compiler-plugin/.svn/dir-prop-base 0.1 kB
- maven-compiler-plugin/.svn/dir-props 0.1 kB
- maven-compiler-plugin/.svn/dir-wcprops 0.1 kB
- maven-compiler-plugin/.svn/empty-file 0.0 kB
- maven-compiler-plugin/.svn/entries 0.7 kB
- maven-compiler-plugin/.svn/format 0.0 kB
- maven-compiler-plugin/.../pom.xml.svn-base 0.1 kB
- maven-compiler-plugin/.../pom.xml.svn-work 0.1 kB
- maven-compiler-plugin/.svn/README.txt 0.1 kB
- maven-compiler-plugin/.../pom.xml.svn-base 1 kB
- maven-compiler-plugin/.../pom.xml.svn-work 0.1 kB
- maven-compiler-plugin/cobertura.ser 13 kB
- maven-compiler-plugin/maven-compiler-plugin.iml 11 kB
- maven-compiler-plugin/maven-compiler-plugin.ipr 4 kB
- maven-compiler-plugin/maven-compiler-plugin.iws 16 kB
- maven-compiler-plugin/pom.xml 2 kB
- maven-compiler-plugin/src/.../dir-wcprops 0.1 kB
- maven-compiler-plugin/src/.../empty-file 0.0 kB
- maven-compiler-plugin/src/.svn/entries 0.4 kB
- maven-compiler-plugin/src/.svn/format 0.0 kB
- maven-compiler-plugin/src/.../README.txt 0.1 kB
- maven-compiler-plugin/src/.../dir-wcprops 0.1 kB
- maven-compiler-plugin/src/.../empty-file 0.0 kB
- maven-compiler-plugin/src/.../.svn/entries 0.4 kB
- maven-compiler-plugin/src/.../.svn/format 0.0 kB
- maven-compiler-plugin/src/.../README.txt 0.1 kB
-
Hide
- maven-jar-plugin.jar
- 10/Mar/06 12:55 PM
- 134 kB
- Jesse McConnell
-
- META-INF/MANIFEST.MF 0.1 kB
- maven-jar-plugin/.classpath 2 kB
- maven-jar-plugin/.project 0.3 kB
- maven-jar-plugin/.svn/dir-prop-base 0.1 kB
- maven-jar-plugin/.svn/dir-props 0.1 kB
- maven-jar-plugin/.svn/dir-wcprops 0.1 kB
- maven-jar-plugin/.svn/empty-file 0.0 kB
- maven-jar-plugin/.svn/entries 0.7 kB
- maven-jar-plugin/.svn/format 0.0 kB
- maven-jar-plugin/.svn/.../pom.xml.svn-base 0.1 kB
- maven-jar-plugin/.svn/.../pom.xml.svn-work 0.1 kB
- maven-jar-plugin/.svn/README.txt 0.1 kB
- maven-jar-plugin/.svn/.../pom.xml.svn-base 1 kB
- maven-jar-plugin/.svn/.../pom.xml.svn-work 0.1 kB
- maven-jar-plugin/maven-jar-plugin.iml 6 kB
- maven-jar-plugin/maven-jar-plugin.ipr 4 kB
- maven-jar-plugin/maven-jar-plugin.iws 15 kB
- maven-jar-plugin/pom.xml 2 kB
- maven-jar-plugin/src/.svn/dir-wcprops 0.1 kB
- maven-jar-plugin/src/.svn/empty-file 0.0 kB
- maven-jar-plugin/src/.svn/entries 0.5 kB
- maven-jar-plugin/src/.svn/format 0.0 kB
- maven-jar-plugin/src/.svn/README.txt 0.1 kB
- maven-jar-plugin/src/.../.svn/dir-wcprops 0.1 kB
- maven-jar-plugin/src/.../.svn/empty-file 0.0 kB
- maven-jar-plugin/src/main/.svn/entries 0.4 kB
- maven-jar-plugin/src/main/.svn/format 0.0 kB
- maven-jar-plugin/src/.../.svn/README.txt 0.1 kB
- maven-jar-plugin/src/.../.svn/dir-wcprops 0.1 kB
- maven-jar-plugin/src/.../.svn/empty-file 0.0 kB
-
- maven-project.patch
- 17/Mar/06 11:48 AM
- 0.5 kB
- Jesse McConnell
Issue Links
- is depended upon by
-
MCLEAN-8
conversion of the existing unit tests to use the AbstractMojoTestCase from the plugin testing harness
-
Activity
I am Dave. Kenney Westerhof pointed me to the apache maven sandbox for an example test project runner maven-it-plugin used for integration tests:
https://svn.apache.org/repos/asf/maven/sandbox/plugins/
Still working on using it with the xmlbeans maven plugin.
Strangely, this issue doesn't have a priority (priority.none).
oh handy, went looking for a jira ticket on this and there it is all assigned to me and everything.
I think the plugin testing harness is moderately useful at this point with a couple of caveats...
I have/or will be soon commiting something that will break it from building against 2.1-SNAPSHOT. That is because to get the StubMavenProject to be instantiated and populated we need an empty constructor on the MavenProject instance I am extending. I have the local change on that but will talk to brett or jason about getting that worked out when I see then again.
On this issue I will also attach the working example of the maven-compiler-plugin where you can see it in action. I'll also attach the simple case for the maven-jar-plugin since that shows how to fill out the maven project stub
I should also say the maven project stub is really dumb at this point and as functionality is needed on it we can implement that as we go.
mojo/mojo-sandbox/maven-plugin-testing/maven-plugin-testing-harness
that is the location of the actual plugin...
I'll write up a confluence page on how to use it more and some things to consider and post the url here later
I was able to get the maven-site-plugin instantiated by adding the plugin harness test dependency and update the maven -site-plugin pom reference to maven-artifact.
IMO that is going to be the biggest limiting factor to this approach, reconsiling the version of dependencies. I have added a mess of dependencies to the plugin-testing-harness pom but they are not used if the project in question has a different version of the dependency, like with the site plugin.
At this point I think we are left with individual details for the framework on a per plugin basis. I implemented most of the maven project stub this morning so it is mostly useful, missing some things but for basic usage should be in decent shape.
two patches for the jar plugin and the compiler plugin to make use of the harness...
added brett as a watcher since he said he would make release a snapshot of the harness and then apply these patchs as examples to work from.
fyi:
this will not compile util we get the MavenProject class to have an empty constructor, I had arranged to have that taken care of but it doesn't look like it has been yet so that is a bit of a hurdle to using this ![]()
I'll include that patch to this issue and hopefully a kind individual can apply it to the trunk
any clues on what you wanted here? is it covered by the integration testing?