You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@continuum.apache.org by Wendy Smoak <ws...@gmail.com> on 2009/04/17 23:13:36 UTC
JUnit vs. TestNG
On Mon, Feb 16, 2009 at 10:24 AM, José Morales Martínez
<jm...@gmv.com> wrote:
> I noticed that the test uses JUnit, version 3.8.1. As a suggestion, I propose the possibility of using TestNG [1]. In TestNG we can config groups, dependencies inter groups, order, timeOut, ... It also allows the use of annotations.
> It's a bit harder to configure, but it has its advantages.
> [1] http://testng.org
Is it time to make a decision on this? I've been applying patches on
both sides, and I have a feeling the tests probably overlap in
functionality by now. Brett mentioned that it's possible to run JUnit
tests with TestNG, maybe that would be a first step towards
consolidation?
--
Wendy
Re: JUnit vs. TestNG
Posted by Brett Porter <br...@apache.org>.
Ok, I'll get it uploaded.
On 20/04/2009, at 11:21 AM, José Morales Martínez wrote:
> I prefer TestNG, but I think we need to upgrade to version 5.9 due
> to a bug related to 'sequential' option for inheritance. This bug
> is fixed in 5.9, although it is not compulsory, it simplifies the
> test and the facility to understand the flow. It is the comment of
> LoginTest class in TestNG test:
>
> /*
> * Bug in TestNG. TESTNG-285: @Test(sequential=true) works
> incorrectly for classes with inheritance
> * http://code.google.com/p/testng/source/browse/trunk/CHANGES.txt
> * Waiting 5.9 release. It's comming soon.
> */
>
> NOTE: I have updated TestNG test. View CONTINUUM-2073.
>
> http://jira.codehaus.org/browse/CONTINUUM-2073
> -----------------------
> Jose
>
>
>
> -----Original Message-----
> From: Brett Porter [mailto:brett@apache.org]
> Sent: lun 20/04/2009 2:59
> To: dev@continuum.apache.org
> Subject: Re: JUnit vs. TestNG
>
> Yeah, just toss them in src/test/java together, Surefire will sort it
> out if you aren't using a suite XML, and if you are they are easy
> enough to add in there.
>
> I definitely prefer TestNG in the long run for the configurability of
> the tests using dependencies and groups, and so on.
>
> - Brett
>
> On 18/04/2009, at 7:13 AM, Wendy Smoak wrote:
>
>> On Mon, Feb 16, 2009 at 10:24 AM, José Morales Martínez
>> <jm...@gmv.com> wrote:
>>
>>> I noticed that the test uses JUnit, version 3.8.1. As a suggestion,
>>> I propose the possibility of using TestNG [1]. In TestNG we can
>>> config groups, dependencies inter groups, order, timeOut, ... It
>>> also allows the use of annotations.
>>> It's a bit harder to configure, but it has its advantages.
>>> [1] http://testng.org
>>
>> Is it time to make a decision on this? I've been applying patches on
>> both sides, and I have a feeling the tests probably overlap in
>> functionality by now. Brett mentioned that it's possible to run
>> JUnit
>> tests with TestNG, maybe that would be a first step towards
>> consolidation?
>>
>> --
>> Wendy
>
>
>
> ______________________
> Este mensaje, y en su caso, cualquier fichero anexo al mismo,
> puede contener informacion clasificada por su emisor como confidencial
> en el marco de su Sistema de Gestion de Seguridad de la
> Informacion siendo para uso exclusivo del destinatario, quedando
> prohibida su divulgacion copia o distribucion a terceros sin la
> autorizacion expresa del remitente. Si Vd. ha recibido este mensaje
> erroneamente, se ruega lo notifique al remitente y proceda a su
> borrado.
> Gracias por su colaboracion.
> ______________________
> This message including any attachments may contain confidential
> information, according to our Information Security Management System,
> and intended solely for a specific individual to whom they are
> addressed.
> Any unauthorised copy, disclosure or distribution of this message
> is strictly forbidden. If you have received this transmission in
> error,
> please notify the sender immediately and delete it.
> ______________________
RE: JUnit vs. TestNG
Posted by José Morales Martínez <jm...@gmv.com>.
I prefer TestNG, but I think we need to upgrade to version 5.9 due to a bug related to 'sequential' option for inheritance. This bug is fixed in 5.9, although it is not compulsory, it simplifies the test and the facility to understand the flow. It is the comment of LoginTest class in TestNG test:
/*
* Bug in TestNG. TESTNG-285: @Test(sequential=true) works incorrectly for classes with inheritance
* http://code.google.com/p/testng/source/browse/trunk/CHANGES.txt
* Waiting 5.9 release. It's comming soon.
*/
NOTE: I have updated TestNG test. View CONTINUUM-2073.
http://jira.codehaus.org/browse/CONTINUUM-2073
-----------------------
Jose
-----Original Message-----
From: Brett Porter [mailto:brett@apache.org]
Sent: lun 20/04/2009 2:59
To: dev@continuum.apache.org
Subject: Re: JUnit vs. TestNG
Yeah, just toss them in src/test/java together, Surefire will sort it
out if you aren't using a suite XML, and if you are they are easy
enough to add in there.
I definitely prefer TestNG in the long run for the configurability of
the tests using dependencies and groups, and so on.
- Brett
On 18/04/2009, at 7:13 AM, Wendy Smoak wrote:
> On Mon, Feb 16, 2009 at 10:24 AM, José Morales Martínez
> <jm...@gmv.com> wrote:
>
>> I noticed that the test uses JUnit, version 3.8.1. As a suggestion,
>> I propose the possibility of using TestNG [1]. In TestNG we can
>> config groups, dependencies inter groups, order, timeOut, ... It
>> also allows the use of annotations.
>> It's a bit harder to configure, but it has its advantages.
>> [1] http://testng.org
>
> Is it time to make a decision on this? I've been applying patches on
> both sides, and I have a feeling the tests probably overlap in
> functionality by now. Brett mentioned that it's possible to run JUnit
> tests with TestNG, maybe that would be a first step towards
> consolidation?
>
> --
> Wendy
______________________
Este mensaje, y en su caso, cualquier fichero anexo al mismo,
puede contener informacion clasificada por su emisor como confidencial
en el marco de su Sistema de Gestion de Seguridad de la
Informacion siendo para uso exclusivo del destinatario, quedando
prohibida su divulgacion copia o distribucion a terceros sin la
autorizacion expresa del remitente. Si Vd. ha recibido este mensaje
erroneamente, se ruega lo notifique al remitente y proceda a su borrado.
Gracias por su colaboracion.
______________________
This message including any attachments may contain confidential
information, according to our Information Security Management System,
and intended solely for a specific individual to whom they are addressed.
Any unauthorised copy, disclosure or distribution of this message
is strictly forbidden. If you have received this transmission in error,
please notify the sender immediately and delete it.
______________________
Re: JUnit vs. TestNG
Posted by Brett Porter <br...@apache.org>.
Yeah, just toss them in src/test/java together, Surefire will sort it
out if you aren't using a suite XML, and if you are they are easy
enough to add in there.
I definitely prefer TestNG in the long run for the configurability of
the tests using dependencies and groups, and so on.
- Brett
On 18/04/2009, at 7:13 AM, Wendy Smoak wrote:
> On Mon, Feb 16, 2009 at 10:24 AM, José Morales Martínez
> <jm...@gmv.com> wrote:
>
>> I noticed that the test uses JUnit, version 3.8.1. As a suggestion,
>> I propose the possibility of using TestNG [1]. In TestNG we can
>> config groups, dependencies inter groups, order, timeOut, ... It
>> also allows the use of annotations.
>> It's a bit harder to configure, but it has its advantages.
>> [1] http://testng.org
>
> Is it time to make a decision on this? I've been applying patches on
> both sides, and I have a feeling the tests probably overlap in
> functionality by now. Brett mentioned that it's possible to run JUnit
> tests with TestNG, maybe that would be a first step towards
> consolidation?
>
> --
> Wendy