Re: NoSuchMethodException using ant junit task against junit 5 5.3.1

Jaikiran Pai <[email protected]>
Newsgroups gmane.comp.jakarta.ant.user
Message-ID <[email protected]>
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.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.