You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Sergey Klimenko (JIRA)" <ji...@codehaus.org> on 2008/08/06 14:23:26 UTC

[jira] Updated: (MSHARED-52) ClassifierFilter throws NullPointerException is artifact has no classifier

     [ http://jira.codehaus.org/browse/MSHARED-52?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Sergey Klimenko updated MSHARED-52:
-----------------------------------

    Attachment: patch

Patch is attached.

> ClassifierFilter throws NullPointerException is artifact has no classifier
> --------------------------------------------------------------------------
>
>                 Key: MSHARED-52
>                 URL: http://jira.codehaus.org/browse/MSHARED-52
>             Project: Maven Shared Components
>          Issue Type: Bug
>          Components: maven-common-artifact-filters
>            Reporter: Sergey Klimenko
>         Attachments: patch
>
>
> If artifact has no classifier attribute when _ClassifierFilter_ throws _NullPointerException_ rather than skip this artifact (because it's classifier doesn't equals required).
> Changes in _TestClassifierFilter_ TestCase:
> {code:title=org.apache.maven.shared.artifact.filter.collection.TestClassifierFilter.java} 
>     protected void setUp() throws Exception
>     {
>         ....
>         artifacts.add(new DefaultArtifact("g", "e", VersionRange.createFromVersion("1.0"), "compile", "jar", null,
>                 new DefaultArtifactHandler("a")));
>     }
> {code} 
> P.S. _ArtifactStubFactory.getClassifiedArtifacts()_ should be changed to return artifact with _null_ classifier.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira