[ https://issues.apache.org/jira/browse/MSHADE-95?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Elliotte Rusty Harold resolved MSHADE-95. ----------------------------------------- Resolution: Won't Fix Since this issue is scheduled for autoclosing due to inactivity anyway, I'm going to be opinionated and say Maven should not support non-test scoped dependencies on test scoped dependencies. The correct solution here is to fix the scopes in the POM. Bundling test scoped dependencies would cause far more problems for correctly scoped products than it would cure for incorrectly scoped projects. > test-scoped artifact excluded, even if it is also a transitive dep > ------------------------------------------------------------------ > > Key: MSHADE-95 > URL: https://issues.apache.org/jira/browse/MSHADE-95 > Project: Maven Shade Plugin > Issue Type: Bug > Affects Versions: 1.3.2, 1.4 > Environment: (cygwin) > Apache Maven 3.0.1 (r1038046; 2010-11-23 05:58:32-0500) > Java version: 1.6.0_23 > Java home: C:\Program Files\Java\jdk1.6.0_23\jre > Default locale: en_US, platform encoding: Cp1252 > OS name: "windows 7" version: "6.1" arch: "amd64" Family: "windows" > Reporter: Alan D. Salewski > Priority: Major > Labels: moreinfo > Attachments: MSHADE-95-IT.patch > > > A test-scoped artifact is excluded from the final jar, even if that artifact > is also a transitive dependency of some other (non-test-scoped) dep. > {noformat} > MY_POM > | > | > +-- dep A (scope: test) > | > | > +-- dep B (scope: compile) > | > | > +-- dep A (scope: compile) > {noformat} > In the above scenario, I would expect '{{dep A}}' to be included in the final > jar, even though it's in the '{{test}}' scope in my POM. The rationale is > that it is required for '{{dep B}}' to run; its absence will result in a > {{java.lang.ClassNotFoundException}} at runtime. > Behavior observed with maven-shade-plugin versions 1.3.2 and 1.4; other > versions not tested. > I'll put together a test case later tonight when I have more time and attach > it here. -- This message was sent by Atlassian Jira (v8.3.4#803005)