Return-Path: X-Original-To: apmail-maven-users-archive@www.apache.org Delivered-To: apmail-maven-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id A2FE51023A for ; Wed, 24 Jul 2013 12:26:47 +0000 (UTC) Received: (qmail 95211 invoked by uid 500); 24 Jul 2013 12:26:44 -0000 Delivered-To: apmail-maven-users-archive@maven.apache.org Received: (qmail 95082 invoked by uid 500); 24 Jul 2013 12:26:41 -0000 Mailing-List: contact users-help@maven.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Maven Users List" Reply-To: "Maven Users List" Delivered-To: mailing list users@maven.apache.org Received: (qmail 94825 invoked by uid 99); 24 Jul 2013 12:26:35 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 24 Jul 2013 12:26:35 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of andreas.dolk.mobil@googlemail.com designates 209.85.214.182 as permitted sender) Received: from [209.85.214.182] (HELO mail-ob0-f182.google.com) (209.85.214.182) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 24 Jul 2013 12:26:28 +0000 Received: by mail-ob0-f182.google.com with SMTP id wo10so330284obc.27 for ; Wed, 24 Jul 2013 05:26:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=d1Minoq3jkq4ldJvJDQ0U5AcRYquY5Z+xQhzZHworJw=; b=dxG+7Fjd48kGRWQfxOOV2fzw05U3auZ03gdn9leikYWummeoCjeGoZhNZXvSmEr/nN KnvD1CEbSxX1QEUoxgIsIUl43dEOoYy9D8rPwAk8VUjhkz5NvWs7SO75QFotyERnYa5R CSVov+rnUU9vBBBXc3mXh/y5c0EWn7EubuTUl5JNNGsHrSCX9aaLS0MA0YHUJa9tlP6c uc82U/0m0n2CWMkcLuWr5UQiy9FMxUrdri2+ykcgCQc2b/Mzmb7bOVanNqvQBx+jqXnu Ds832z2YxVZZwsulCJt47b+axbqtaq1k68iYmM1x6FGYTmo++yl6lyTgy7TpJvgwMRwX jgYg== MIME-Version: 1.0 X-Received: by 10.43.67.3 with SMTP id xs3mr19432740icb.45.1374668766898; Wed, 24 Jul 2013 05:26:06 -0700 (PDT) Received: by 10.50.219.135 with HTTP; Wed, 24 Jul 2013 05:26:06 -0700 (PDT) In-Reply-To: References: Date: Wed, 24 Jul 2013 14:26:06 +0200 Message-ID: Subject: Re: maven surefire - selecting providers From: Andreas Dolk To: Maven Users List Content-Type: multipart/alternative; boundary=001a11c2162e88f2cd04e24103a1 X-Virus-Checked: Checked by ClamAV on apache.org --001a11c2162e88f2cd04e24103a1 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Ah sure, sorry: jUnit: 4.11 TestNG: 6.8.5 And thanks for the "mixed mode" hint, I study the reference, maybe I find something in the build files! Best regards, Andreas 2013/7/24 Francesco Mari > I still wasn't able to reproduce your issue. > > Looks like TestNG is running in "mixed mode" [1][2]. The last missing > information is the version of JUnit and TestNG you are using. Can you > provide this piece of configuration? > > [1]: http://testng.org/doc/migrating.html > [2]: http://testng.org/doc/documentation-main.html#junit > > > 2013/7/24 Andreas Dolk > > > Hi Francesco, > > > > I'm using 2.15 > > > > And here's the result from a test run, that's what happens. The tests a= re > > *only* jUnit tests. I've only replaced path and package names. BTW, the > > jUnit times are net execution times (unfair!!), testNG reports the tota= l > > times (fair) ;) The other annoying part is that TestNG picks up far mor= e > > classes then jUnit... > > > > The tests are auto-compiled from jnario specs (jnario.org) which > shouldn't > > make a difference - at the end it's classes compiled from java source > > files. > > > > Regards, > > Andreas > > > > > > > > > mvn -Dtest=3DJnSpec* test > > > > ... > > > > [INFO] --- maven-surefire-plugin:2.15:test (default-test) @ a42-order-b= e > > --- > > [INFO] Surefire report directory: //target/surefire-reports > > [INFO] Using configured provider > > org.apache.maven.surefire.junitcore.JUnitCoreProvider > > [INFO] Using configured provider > > org.apache.maven.surefire.testng.TestNGProvider > > [INFO] parallel=3D'none', perCoreThreadCount=3Dtrue, threadCount=3D2, > > useUnlimitedThreads=3Dfalse > > > > ------------------------------------------------------- > > T E S T S > > ------------------------------------------------------- > > > > ------------------------------------------------------- > > T E S T S > > ------------------------------------------------------- > > Running .JnSpecBPMNProcessSpec > > Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.199 > sec - > > in .JnSpecBPMNProcessSpec > > Running .JnSpecCreateTheResultMessageOfACancellationSpec > > Tests run: 3, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.485 > sec - > > in .JnSpecCreateTheResultMessageOfACancellationSpec > > Running > .JnSpecServicesToSupportCancellationOfItemsOfOneOrderSpec > > Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.471 > sec - > > in .JnSpecServicesToSupportCancellationOfItemsOfOneOrderSpec > > Running > > > .JnSpecServicesToSupportCancellationOfItemsOfOnePurchaseOrderSpe= c > > Tests run: 3, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.975 > sec - > > in > > > .JnSpecServicesToSupportCancellationOfItemsOfOnePurchaseOrderSpe= c > > Running > > > > > .JnSpecVerifyingTheCancellationMessageACancelRequestWithAnAlread= yDeliveredOrderitemSpec > > Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.262 > sec - > > in > > > > > .JnSpecVerifyingTheCancellationMessageACancelRequestWithAnAlread= yDeliveredOrderitemSpec > > Running > > > > > .JnSpecVerifyingTheCancellationMessageACancelRequestWithAnUndeli= veredOrderitemSpec > > Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.215 > sec - > > in > > > > > .JnSpecVerifyingTheCancellationMessageACancelRequestWithAnUndeli= veredOrderitemSpec > > Running > > > > > .JnSpecVerifyingTheCancellationMessageACancelRequestWithAnAlread= yDeliveredOrderitemSpec > > Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.225 > sec - > > in > > > > > .JnSpecVerifyingTheCancellationMessageACancelRequestWithAnAlread= yDeliveredOrderitemSpec > > Running > > > > > .JnSpecVerifyingTheCancellationMessageACancelRequestWithAnUndeli= veredOrderitemSpec > > Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.028 > sec - > > in > > > > > .JnSpecVerifyingTheCancellationMessageACancelRequestWithAnUndeli= veredOrderitemSpec > > > > Results : > > > > Tests run: 14, Failures: 0, Errors: 0, Skipped: 0 > > > > > > ------------------------------------------------------- > > T E S T S > > ------------------------------------------------------- > > > > ------------------------------------------------------- > > T E S T S > > ------------------------------------------------------- > > Running .JnSpecBPMNProcessSpec$1 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.595 > sec - > > in .JnSpecBPMNProcessSpec$1 > > Running .JnSpecBPMNProcessSpec > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.693 > sec - > > in .JnSpecBPMNProcessSpec > > Running .JnSpecCreateTheResultMessageOfACancellationSpec$1 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.658 > sec - > > in .JnSpecCreateTheResultMessageOfACancellationSpec$1 > > Running .JnSpecCreateTheResultMessageOfACancellationSpec$2$1 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.683 > sec - > > in .JnSpecCreateTheResultMessageOfACancellationSpec$2$1 > > Running .JnSpecCreateTheResultMessageOfACancellationSpec$2 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.621 > sec - > > in .JnSpecCreateTheResultMessageOfACancellationSpec$2 > > Running .JnSpecCreateTheResultMessageOfACancellationSpec$3 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.534 > sec - > > in .JnSpecCreateTheResultMessageOfACancellationSpec$3 > > Running .JnSpecCreateTheResultMessageOfACancellationSpec$4$1$1 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.572 > sec - > > in .JnSpecCreateTheResultMessageOfACancellationSpec$4$1$1 > > Running .JnSpecCreateTheResultMessageOfACancellationSpec$4$1 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.142 > sec - > > in .JnSpecCreateTheResultMessageOfACancellationSpec$4$1 > > Running .JnSpecCreateTheResultMessageOfACancellationSpec$4 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.678 > sec - > > in .JnSpecCreateTheResultMessageOfACancellationSpec$4 > > Running .JnSpecCreateTheResultMessageOfACancellationSpec$5$1 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.989 > sec - > > in .JnSpecCreateTheResultMessageOfACancellationSpec$5$1 > > Running .JnSpecCreateTheResultMessageOfACancellationSpec$5 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.461 > sec - > > in .JnSpecCreateTheResultMessageOfACancellationSpec$5 > > Running .JnSpecCreateTheResultMessageOfACancellationSpec > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.8 sec= - > > in .JnSpecCreateTheResultMessageOfACancellationSpec > > Running > > .JnSpecServicesToSupportCancellationOfItemsOfOneOrderSpec$1 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 3.138 > sec - > > in .JnSpecServicesToSupportCancellationOfItemsOfOneOrderSpec$1 > > Running > > .JnSpecServicesToSupportCancellationOfItemsOfOneOrderSpec$2 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.404 > sec - > > in .JnSpecServicesToSupportCancellationOfItemsOfOneOrderSpec$2 > > Running > > .JnSpecServicesToSupportCancellationOfItemsOfOneOrderSpec$3 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.746 > sec - > > in .JnSpecServicesToSupportCancellationOfItemsOfOneOrderSpec$3 > > Running > > .JnSpecServicesToSupportCancellationOfItemsOfOneOrderSpec$4 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.242 > sec - > > in .JnSpecServicesToSupportCancellationOfItemsOfOneOrderSpec$4 > > Running > .JnSpecServicesToSupportCancellationOfItemsOfOneOrderSpec > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.571 > sec - > > in .JnSpecServicesToSupportCancellationOfItemsOfOneOrderSpec > > Running > > > > > .JnSpecServicesToSupportCancellationOfItemsOfOnePurchaseOrderSpe= c$1 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.28 se= c > - > > in > > > > > .JnSpecServicesToSupportCancellationOfItemsOfOnePurchaseOrderSpe= c$1 > > Running > > > > > .JnSpecServicesToSupportCancellationOfItemsOfOnePurchaseOrderSpe= c$2 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.334 > sec - > > in > > > > > .JnSpecServicesToSupportCancellationOfItemsOfOnePurchaseOrderSpe= c$2 > > Running > > > > > .JnSpecServicesToSupportCancellationOfItemsOfOnePurchaseOrderSpe= c$3 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.363 > sec - > > in > > > > > .JnSpecServicesToSupportCancellationOfItemsOfOnePurchaseOrderSpe= c$3 > > Running > > > > > .JnSpecServicesToSupportCancellationOfItemsOfOnePurchaseOrderSpe= c$4 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.148 > sec - > > in > > > > > .JnSpecServicesToSupportCancellationOfItemsOfOnePurchaseOrderSpe= c$4 > > Running > > > > > .JnSpecServicesToSupportCancellationOfItemsOfOnePurchaseOrderSpe= c$5 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.506 > sec - > > in > > > > > .JnSpecServicesToSupportCancellationOfItemsOfOnePurchaseOrderSpe= c$5 > > Running > > > .JnSpecServicesToSupportCancellationOfItemsOfOnePurchaseOrderSpe= c > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.767 > sec - > > in > > > .JnSpecServicesToSupportCancellationOfItemsOfOnePurchaseOrderSpe= c > > Running > > > > > .JnSpecVerifyingTheCancellationMessageACancelRequestWithAnAlread= yDeliveredOrderitemSpec > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.883 > sec - > > in > > > > > .JnSpecVerifyingTheCancellationMessageACancelRequestWithAnAlread= yDeliveredOrderitemSpec > > Running > > > > > .JnSpecVerifyingTheCancellationMessageACancelRequestWithAnUndeli= veredOrderitemSpec > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.606 > sec - > > in > > > > > .JnSpecVerifyingTheCancellationMessageACancelRequestWithAnUndeli= veredOrderitemSpec > > Running .JnSpecVerifyingTheCancellationMessageSpec$1 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.275 > sec - > > in .JnSpecVerifyingTheCancellationMessageSpec$1 > > Running .JnSpecVerifyingTheCancellationMessageSpec$2 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.147 > sec - > > in .JnSpecVerifyingTheCancellationMessageSpec$2 > > Running .JnSpecVerifyingTheCancellationMessageSpec$3 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 4.246 > sec - > > in .JnSpecVerifyingTheCancellationMessageSpec$3 > > Running .JnSpecVerifyingTheCancellationMessageSpec$4$1$1$1$1 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.514 > sec - > > in .JnSpecVerifyingTheCancellationMessageSpec$4$1$1$1$1 > > Running .JnSpecVerifyingTheCancellationMessageSpec$4$1$1$1 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.406 > sec - > > in .JnSpecVerifyingTheCancellationMessageSpec$4$1$1$1 > > Running .JnSpecVerifyingTheCancellationMessageSpec$4$1$1 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.614 > sec - > > in .JnSpecVerifyingTheCancellationMessageSpec$4$1$1 > > Running .JnSpecVerifyingTheCancellationMessageSpec$4$1 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.569 > sec - > > in .JnSpecVerifyingTheCancellationMessageSpec$4$1 > > Running .JnSpecVerifyingTheCancellationMessageSpec$4 > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.538 > sec - > > in .JnSpecVerifyingTheCancellationMessageSpec$4 > > Running .JnSpecVerifyingTheCancellationMessageSpec > > Configuring TestNG with: TestNG652Configurator > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 2.459 > sec - > > in .JnSpecVerifyingTheCancellationMessageSpec > > > > Results : > > > > Tests run: 0, Failures: 0, Errors: 0, Skipped: 0 > > > > [INFO] > > -----------------------------------------------------------------------= - > > [INFO] BUILD SUCCESS > > [INFO] > > -----------------------------------------------------------------------= - > > > > > > > > 2013/7/24 Francesco Mari > > > > > I tried to reproduce the problem with the version 2.14.1 of the plugi= n, > > but > > > everything works correctly. Which version of the plugin are you using= ? > > > > > > > > > 2013/7/24 Andreas Dolk > > > > > > > Sure, here we go: > > > > > > > > > > > > org.apache.maven.plugins > > > > maven-surefire-plugin > > > > > ${version.maven-surefire-plugin} > > > > > > > > > > > > > > org.apache.maven.surefire > > > > surefire-junit47 > > > > > > > > ${version.maven-surefire-plugin} > > > > > > > > > > > > > > org.apache.maven.surefire > > > > surefire-testng > > > > > > > > ${version.maven-surefire-plugin} > > > > > > > > > > > > > > > > > > > > **/*Spec*.java > > > > **/*Feature.java > > > > **/*Test.java > > > > **/*TestCase.java > > > > > > > > 1 > > > > false > > > > > > > > > > > > > > > > > > > > > > > > Andreas > > > > > > > > > > > > 2013/7/24 Francesco Mari > > > > > > > > > Can you provide your configuration for the m-surefire-p? > > > > > > > > > > > > > > > 2013/7/24 Andreas Dolk > > > > > > > > > > > Hello all, > > > > > > > > > > > > we have maven builds for projects that use both jUnit and testN= G > > > tests. > > > > > So > > > > > > I configured the maven surefire plugin to use multiple provider= s > ( > > > > > > > > > > > > > > > > > > > > > > > > > > > http://maven.apache.org/surefire/maven-surefire-plugin/examples/providers= .html > > > > > > ) > > > > > > and it works pretty well - apart from the problem, that now > TestNG > > > > tries > > > > > to > > > > > > run every single jUnit test in the project. It takes about 2 > > seconds > > > > for > > > > > > each test until it finds out that it has nothing to to (only > jUnit > > > > > > annotations on the test class) > > > > > > > > > > > > The annoying part is that now some tests that failed with jUnit > are > > > > > marked > > > > > > ok after TestNG didn't find a problem. > > > > > > > > > > > > Is there anyway to configure surefire or the providers so that > they > > > > only > > > > > > run "their own" tests and ignore the others? A solution where > > rename > > > > the > > > > > > test to filter by names would be fine for me. > > > > > > > > > > > > Best regards, > > > > > > > > > > > > > > > > > > Andreas > > > > > > > > > > > > > > > > > > > > > > > > > > > -- > > > > Andreas Dolk > > > > > > > > Zurmainerstra=C3=9Fe 33 > > > > D-54292 Trier > > > > Phone=E3=80=8C+49 651 4362884=E3=80=8D > > > > Mobile=E3=80=8C+49 177 4970815=E3=80=8D > > > > EMail=E3=80=8Candreas.dolk.mobil@googlemail.com=E3=80=8D > > > > > > > > > > > > > > > -- > > Andreas Dolk > > > > Zurmainerstra=C3=9Fe 33 > > D-54292 Trier > > Phone=E3=80=8C+49 651 4362884=E3=80=8D > > Mobile=E3=80=8C+49 177 4970815=E3=80=8D > > EMail=E3=80=8Candreas.dolk.mobil@googlemail.com=E3=80=8D > > > --=20 Andreas Dolk Zurmainerstra=C3=9Fe 33 D-54292 Trier Phone=E3=80=8C+49 651 4362884=E3=80=8D Mobile=E3=80=8C+49 177 4970815=E3=80=8D EMail=E3=80=8Candreas.dolk.mobil@googlemail.com=E3=80=8D --001a11c2162e88f2cd04e24103a1--