[ https://issues.apache.org/jira/browse/MDEP-532?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17894733#comment-17894733 ]
Alexander Kriegisch commented on MDEP-532: ------------------------------------------ [~elharo], I am unsure how to get your attention. I want to avoid creating a duplicate bug just to get this reopened. Would you please read the bug description and my comments one more time? The problem is *not* that the plugin is executed incorrectly. The problem is that, no matter how the plugin is executed (Maven phase or direct plugin execution via CLI), it reports a test dependency despite {{<ignoreNonCompile>true</ignoreNonCompile>}}. That behaviour remains after your suggested "fix". You must have got lost in trying to reproduce it via {{mvn dependency:analyze}} instead of {{mvn verify}}. But still, in https://issues.apache.org/jira/browse/MDEP-532?focusedCommentId=17891563&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-17891563 you clearly see the falsely reported test dependency. > Undeclared test resources fail build despite 'ignoreNonCompile' > --------------------------------------------------------------- > > Key: MDEP-532 > URL: https://issues.apache.org/jira/browse/MDEP-532 > Project: Maven Dependency Plugin > Issue Type: Bug > Components: analyze > Affects Versions: 2.10 > Environment: Windows 7 Pro 64-bit, Java OpenSDK 8, Maven 3.3.9 > Reporter: Alexander Kriegisch > Assignee: Elliotte Rusty Harold > Priority: Minor > Labels: S2 > > I have this plugin in my project's root POM: > {code} > <plugin> > <groupId>org.apache.maven.plugins</groupId> > <artifactId>maven-dependency-plugin</artifactId> > <version>2.10</version> > <executions> > <execution> > <id>analyze</id> > <goals> > <goal>analyze-only</goal> > </goals> > <configuration> > <failOnWarning>true</failOnWarning> > <ignoreNonCompile>true</ignoreNonCompile> > > <ignoredUnusedDeclaredDependencies>*</ignoredUnusedDeclaredDependencies> > </configuration> > </execution> > </executions> > </plugin> > {code} > Even though I want to ignore used undeclared test dependencies via > {{<ignoreNonCompile>true</ignoreNonCompile>}}, my build fails like this in > several modules: > {code} > [INFO] --- maven-dependency-plugin:2.10:analyze-only (analyze) @ xxx.yyy --- > [WARNING] Used undeclared dependencies found: > [WARNING] > org.jboss.shrinkwrap.resolver:shrinkwrap-resolver-api-maven:jar:2.2.0:test > [WARNING] org.jboss.shrinkwrap:shrinkwrap-api:jar:1.2.3:test > [WARNING] > org.jboss.arquillian.container:arquillian-container-test-api:jar:1.1.11.Final:test > [WARNING] > org.jboss.arquillian.spock:arquillian-spock-core:jar:1.0.0.RC4_XXX:test > [WARNING] > org.jboss.shrinkwrap.resolver:shrinkwrap-resolver-api-maven-archive:jar:2.2.0:test > (...) > [ERROR] Failed to execute goal > org.apache.maven.plugins:maven-dependency-plugin:2.10:analyze-only (analyze) > on project xxx.yyy: Dependency problems found -> [Help 1] > [ERROR] Failed to execute goal > org.apache.maven.plugins:maven-dependency-plugin:2.10:analyze-only (analyze) > on project yyy.zzz: Dependency problems found -> [Help 1] > [ERROR] Failed to execute goal > org.apache.maven.plugins:maven-dependency-plugin:2.10:analyze-only (analyze) > on project zzz.aaa: Dependency problems found -> [Help 1] > [ERROR] Failed to execute goal > org.apache.maven.plugins:maven-dependency-plugin:2.10:analyze-only (analyze) > on project aaa.bbb: Dependency problems found -> [Help 1] > {code} -- This message was sent by Atlassian Jira (v8.20.10#820010)