You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ant.apache.org by Stefan Bodewig <bo...@apache.org> on 2018/03/20 15:27:54 UTC

junitlauncher dependency on JUnit4?

Hi

I've just added a POM for ant-junitlauncher and it currently fails to
build as
org.apache.tools.ant.taskdefs.optional.junitlauncher.SingleTestClass has
a dependency on org.junit.Test and I haven't declared any dependency on
JUnit4 inside the POM (only transitively with scope test).

The class has an @Test annotation inside of the main build tree, is this
intentional? To me it looks as if the annotation and the import of
org.junit.Test could be removed.

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Re: junitlauncher dependency on JUnit4?

Posted by Gintautas Grigelionis <g....@gmail.com>.
2018-03-20 16:43 GMT+01:00 Stefan Bodewig <bo...@apache.org>:

> On 2018-03-20, Gintautas Grigelionis wrote:
>
> > My understanding is that junitlauncher has a dependency on JUnit 4
> through
> > vintage engine. I guess pom should provide profiles for engine choice.
> See
> > my earlier questions re the task classpath.
>
> Only when running the tests. The launcher task itself doesn't depend on
> any of the engines at compile time.
>

At least in pom there is a clear distinction between compile and runtime.
I wish there was Ivy 2.5 out there so that we could have a unified ivy.xml;
until then -- sorry for thinking as an end user in terms of dependencies.

Gintas

Re: junitlauncher dependency on JUnit4?

Posted by Stefan Bodewig <bo...@apache.org>.
On 2018-03-20, Gintautas Grigelionis wrote:

> My understanding is that junitlauncher has a dependency on JUnit 4 through
> vintage engine. I guess pom should provide profiles for engine choice. See
> my earlier questions re the task classpath.

Only when running the tests. The launcher task itself doesn't depend on
any of the engines at compile time.

> Den tis 20 mars 2018 16:28Stefan Bodewig <bo...@apache.org> skrev:

>> I've just added a POM for ant-junitlauncher and it currently fails to
>> build as
>> org.apache.tools.ant.taskdefs.optional.junitlauncher.SingleTestClass has
>> a dependency on org.junit.Test and I haven't declared any dependency on
>> JUnit4 inside the POM (only transitively with scope test).

This class is in src/main and the test works fine even if I remove the
@Test annotation.

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Re: junitlauncher dependency on JUnit4?

Posted by Gintautas Grigelionis <g....@gmail.com>.
My understanding is that junitlauncher has a dependency on JUnit 4 through
vintage engine. I guess pom should provide profiles for engine choice. See
my earlier questions re the task classpath.

Gintas

Den tis 20 mars 2018 16:28Stefan Bodewig <bo...@apache.org> skrev:

> Hi
>
> I've just added a POM for ant-junitlauncher and it currently fails to
> build as
> org.apache.tools.ant.taskdefs.optional.junitlauncher.SingleTestClass has
> a dependency on org.junit.Test and I haven't declared any dependency on
> JUnit4 inside the POM (only transitively with scope test).
>
> The class has an @Test annotation inside of the main build tree, is this
> intentional? To me it looks as if the annotation and the import of
> org.junit.Test could be removed.
>
> Stefan
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
> For additional commands, e-mail: dev-help@ant.apache.org
>
>

Re: junitlauncher dependency on JUnit4?

Posted by Stefan Bodewig <bo...@apache.org>.
On 2018-03-20, Jaikiran Pai wrote:

> This looks like some odd merge or squashing issue when I pushed that
> task changes. I have fixed it. The task itself doesn't need any JUnit
> test engine specific dependencies like this one. I just pushed the
> commit upstream which should fix this.

Looks good, building from POMs now works on master. Thanks.

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Re: junitlauncher dependency on JUnit4?

Posted by Jaikiran Pai <ja...@gmail.com>.
Hi Stefan,

This looks like some odd merge or squashing issue when I pushed that 
task changes. I have fixed it. The task itself doesn't need any JUnit 
test engine specific dependencies like this one. I just pushed the 
commit upstream which should fix this.

P.S: I haven't responded to some other mails due to limited internet 
connectivity this few days. I'll respond to them soon.

-Jaikiran


On 20/03/18 8:57 PM, Stefan Bodewig wrote:
> Hi
>
> I've just added a POM for ant-junitlauncher and it currently fails to
> build as
> org.apache.tools.ant.taskdefs.optional.junitlauncher.SingleTestClass has
> a dependency on org.junit.Test and I haven't declared any dependency on
> JUnit4 inside the POM (only transitively with scope test).
>
> The class has an @Test annotation inside of the main build tree, is this
> intentional? To me it looks as if the annotation and the import of
> org.junit.Test could be removed.
>
> Stefan
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
> For additional commands, e-mail: dev-help@ant.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org