From 43d32fdfea47f19c876766559e2d3202afc61010 Mon Sep 17 00:00:00 2001 From: Benjamin Bentmann Date: Sat, 21 Feb 2009 14:31:06 +0000 Subject: [PATCH] o Added IT to check help mojo generation git-svn-id: https://svn.apache.org/repos/asf/maven/plugin-tools/trunk@746519 13f79535-47bb-0310-9956-ffa450edef68 --- .../src/it/help-basic/invoker.properties | 2 + maven-plugin-plugin/src/it/help-basic/pom.xml | 63 +++++++++++++++++++ .../help-basic/src/main/java/test/MyMojo.java | 43 +++++++++++++ .../src/it/help-basic/test.properties | 2 + 4 files changed, 110 insertions(+) create mode 100644 maven-plugin-plugin/src/it/help-basic/invoker.properties create mode 100644 maven-plugin-plugin/src/it/help-basic/pom.xml create mode 100644 maven-plugin-plugin/src/it/help-basic/src/main/java/test/MyMojo.java create mode 100644 maven-plugin-plugin/src/it/help-basic/test.properties diff --git a/maven-plugin-plugin/src/it/help-basic/invoker.properties b/maven-plugin-plugin/src/it/help-basic/invoker.properties new file mode 100644 index 0000000..5b282bb --- /dev/null +++ b/maven-plugin-plugin/src/it/help-basic/invoker.properties @@ -0,0 +1,2 @@ +invoker.goals.1 = install +invoker.goals.2 = org.apache.maven.its.plugin:help:1.0:help diff --git a/maven-plugin-plugin/src/it/help-basic/pom.xml b/maven-plugin-plugin/src/it/help-basic/pom.xml new file mode 100644 index 0000000..0121194 --- /dev/null +++ b/maven-plugin-plugin/src/it/help-basic/pom.xml @@ -0,0 +1,63 @@ + + + + + + 4.0.0 + + org.apache.maven.its.plugin + help + 1.0 + maven-plugin + + + Tests generation and compilation of the help mojo. + + + + UTF-8 + + + + + org.apache.maven + maven-plugin-api + 2.0 + + + + + + + org.apache.maven.plugins + maven-plugin-plugin + @project.version@ + + + help-goal + + helpmojo + + + + + + + diff --git a/maven-plugin-plugin/src/it/help-basic/src/main/java/test/MyMojo.java b/maven-plugin-plugin/src/it/help-basic/src/main/java/test/MyMojo.java new file mode 100644 index 0000000..f7a5d59 --- /dev/null +++ b/maven-plugin-plugin/src/it/help-basic/src/main/java/test/MyMojo.java @@ -0,0 +1,43 @@ +package test; + +import org.apache.maven.plugin.AbstractMojo; + +/** + * MOJO-DESCRIPTION. Some "quotation" marks and backslashes '\\', some important javadoc
and an + * inline link to {@link test.AnotherMojo}. + * + * @goal test + * @deprecated As of 1.0, use the "quoted" goal instead. + * @since 2.1 + */ +public class MyMojo + extends AbstractMojo +{ + + /** + * This parameter uses "quotation" marks and backslashes '\\' in its description. Those characters must be + * escaped in Java string literals. + * + * @parameter default-value="escape\\backslash" + * @since 2.0 + */ + private String defaultParam; + + /** + * This parameter is deprecated. + * + * @parameter + * @deprecated As of version 1.0, us the {@link #defaultParam} instead. + */ + private String deprecatedParam; + + /** + * @parameter expression="${test.undocumented}" + */ + private String undocumentedParam; + + public void execute() + { + } + +} diff --git a/maven-plugin-plugin/src/it/help-basic/test.properties b/maven-plugin-plugin/src/it/help-basic/test.properties new file mode 100644 index 0000000..70adb08 --- /dev/null +++ b/maven-plugin-plugin/src/it/help-basic/test.properties @@ -0,0 +1,2 @@ +detail = true +goal = test