Hi people

I'm trying to produce a fix for the cobertura mojo. When it instruments the
code, it adds cobertura as a dependency to the projects 'test' cycle by
doing

       this.project.setDependencyArtifacts( set );
where the set has included the artifact cobertura-1.7 in the 'test' scope.

The problem is, is that the cobertura POM includes asm-2.1. This is a
dependency for running cobertura to *instrument* the code, but it is not a
dependency (and prevents it from working for hibernate projects) a
dependency at runtime.

I hoped I might be able to add a filter in order to prevent this happening -
however I think the bit where the filter is used
(DefaultPluginManager::resolveTransitiveDependencies) manually just creates
a ScopeArtifactFilter, so I have no opportunity to change it to something
that might scope out the dependency.

Am I barking up the wrong tree here, or is there a better way of trying to
do this?

Reply via email to