NoSuchMethodException using ant junit task against junit 5 5.3.1

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

NoSuchMethodException using ant junit task against junit 5 5.3.1

Dave Brosius-2
I am running ant 1.10.5 against the 5.3.1/1.3.1 of junit 5 and getting

java.lang.NoSuchMethodError:
org.apache.tools.ant.types.CommandlineJava.clone()Lorg/apache/tools/ant/types/CommandlineJava;



Anyone know what i'm missing? It works fine with 5.2.0/1.2.0.
--





---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: NoSuchMethodException using ant junit task against junit 5 5.3.1

Jaikiran Pai-2
Hello Dave,

Can you add some details like what jars (especially the ones that
contain the Ant JUnit task classes) are present in the classpath? An
output of ant -v <target> might also be useful.

There was an unintentional change in one of 1.10.x releases which
affected the signature of the clone() method of CommandlineJava class.
That change was reverted in a subsequent release of 1.10.x. My guess,
based on that exception message is that the ant-junit.jar that you have
in classpath is from a version which had that unintentional change. If
you can ensure that the ant-junit.jar in your classpath is from 1.10.5,
then I think you will get past this.

Having said that, I don't know how the version of the JUnit 5 libraries
itself should impact any of this.

-Jaikiran


On 04/10/18 10:22 AM, Dave Brosius wrote:
> I am running ant 1.10.5 against the 5.3.1/1.3.1 of junit 5 and getting
>
> java.lang.NoSuchMethodError:
> org.apache.tools.ant.types.CommandlineJava.clone()Lorg/apache/tools/ant/types/CommandlineJava;
>
>
>
> Anyone know what i'm missing? It works fine with 5.2.0/1.2.0.


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]