You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Antony Stubbs (Jira)" <ji...@apache.org> on 2021/08/09 13:04:00 UTC

[jira] [Commented] (MPLUGINTESTING-57) plugin.xml is needed

    [ https://issues.apache.org/jira/browse/MPLUGINTESTING-57?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17396029#comment-17396029 ] 

Antony Stubbs commented on MPLUGINTESTING-57:
---------------------------------------------

The maven plugin archetype also appears to produce a test which cannot run, due to this error:

 

{{junit.framework.AssertionFailedError: The MojoDescriptor for the goal touch cannot be null.}}
{{at junit.framework.Assert.fail(Assert.java:57) at junit.framework.Assert.assertTrue(Assert.java:22) at junit.framework.Assert.assertNotNull(Assert.java:256) at junit.framework.TestCase.assertNotNull(TestCase.java:426) at org.apache.maven.plugin.testing.AbstractMojoTestCase.newMojoExecution(AbstractMojoTestCase.java:515) at org.apache.maven.plugin.testing.MojoRule.newMojoExecution(MojoRule.java:207) at org.apache.maven.plugin.testing.MojoRule.lookupConfiguredMojo(MojoRule.java:354) at }}

> plugin.xml is needed
> --------------------
>
>                 Key: MPLUGINTESTING-57
>                 URL: https://issues.apache.org/jira/browse/MPLUGINTESTING-57
>             Project: Maven Plugin Testing
>          Issue Type: Improvement
>          Components: plugin-testing-harness
>    Affects Versions: 3.3.0
>            Reporter: Gerrit Hohl
>            Priority: Major
>
> For the test being executable the plugin.xml created by the maven-plugin-plugin is needed. But this plugin only runs during the build time of the Maven project of your plugin. If I use e.g. Eclipse and JUnit I don't have this file. But I guess it should be possible to get all the needed information also during runtime of the test as the maven-plugin-plugin also doesn't have any extra sources beside the Mojo and its annotations.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)