I'm using the invoker plugin to test the mojo I'm hacking.

I had assumed that the mojo's classpath would be available to invoker, but
when I print out the classpath that doesn't appear to be the case.

I've tried the addTestClassPath option but then I'm getting
groovy.lang.GroovyRuntimeException: Failed to create Script instance for
class: class Script1. Reason: java.lang.ClassCastException: Script1 cannot
be cast to groovy.lang.GroovyObject

Which looks a bit like https://issues.apache.org/jira/browse/MINVOKER-112.

If I add in the dependency directly to the maven-invoker-plugin then I can
keep working.

What's the correct way?

Reply via email to