maven-wagon git commit: [WAGON-458] FTPSClient for Wagon
Repository: maven-wagon Updated Branches: refs/heads/master ffa7fc883 -> e30c31d4b [WAGON-458] FTPSClient for Wagon Submitted by: Witek Project: http://git-wip-us.apache.org/repos/asf/maven-wagon/repo Commit: http://git-wip-us.apache.org/repos/asf/maven-wagon/commit/e30c31d4 Tree: http://git-wip-us.apache.org/repos/asf/maven-wagon/tree/e30c31d4 Diff: http://git-wip-us.apache.org/repos/asf/maven-wagon/diff/e30c31d4 Branch: refs/heads/master Commit: e30c31d4bd0762ec0ec54ae44fc1f3ef407c81c1 Parents: ffa7fc8 Author: trand8Authored: Thu Dec 1 20:40:44 2016 -0800 Committer: trand8 Committed: Thu Dec 1 20:40:44 2016 -0800 -- wagon-providers/wagon-ftp/pom.xml | 2 +- .../maven/wagon/providers/ftp/FtpWagon.java | 7 ++- .../maven/wagon/providers/ftp/FtpsWagon.java| 64 .../wagon-ftp/src/site/apt/index.apt| 63 ++- 4 files changed, 133 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/maven-wagon/blob/e30c31d4/wagon-providers/wagon-ftp/pom.xml -- diff --git a/wagon-providers/wagon-ftp/pom.xml b/wagon-providers/wagon-ftp/pom.xml index 2755a57..8cec0c9 100644 --- a/wagon-providers/wagon-ftp/pom.xml +++ b/wagon-providers/wagon-ftp/pom.xml @@ -37,7 +37,7 @@ under the License. commons-net commons-net - 3.1 + 3.5 http://git-wip-us.apache.org/repos/asf/maven-wagon/blob/e30c31d4/wagon-providers/wagon-ftp/src/main/java/org/apache/maven/wagon/providers/ftp/FtpWagon.java -- diff --git a/wagon-providers/wagon-ftp/src/main/java/org/apache/maven/wagon/providers/ftp/FtpWagon.java b/wagon-providers/wagon-ftp/src/main/java/org/apache/maven/wagon/providers/ftp/FtpWagon.java index 455d3f4..4fa0fd6 100644 --- a/wagon-providers/wagon-ftp/src/main/java/org/apache/maven/wagon/providers/ftp/FtpWagon.java +++ b/wagon-providers/wagon-ftp/src/main/java/org/apache/maven/wagon/providers/ftp/FtpWagon.java @@ -112,7 +112,7 @@ public class FtpWagon String host = getRepository().getHost(); -ftp = new FTPClient(); +ftp = createClient(); ftp.setDefaultTimeout( getTimeout() ); ftp.setDataTimeout( getTimeout() ); ftp.setControlEncoding( getControlEncoding() ); @@ -187,6 +187,11 @@ public class FtpWagon } } +protected FTPClient createClient() +{ +return new FTPClient(); +} + protected void firePutCompleted( Resource resource, File file ) { try http://git-wip-us.apache.org/repos/asf/maven-wagon/blob/e30c31d4/wagon-providers/wagon-ftp/src/main/java/org/apache/maven/wagon/providers/ftp/FtpsWagon.java -- diff --git a/wagon-providers/wagon-ftp/src/main/java/org/apache/maven/wagon/providers/ftp/FtpsWagon.java b/wagon-providers/wagon-ftp/src/main/java/org/apache/maven/wagon/providers/ftp/FtpsWagon.java new file mode 100644 index 000..3736449 --- /dev/null +++ b/wagon-providers/wagon-ftp/src/main/java/org/apache/maven/wagon/providers/ftp/FtpsWagon.java @@ -0,0 +1,64 @@ +package org.apache.maven.wagon.providers.ftp; + +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +import org.apache.commons.net.ftp.FTPClient; +import org.apache.commons.net.ftp.FTPSClient; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +/** + * FtpsWagon + * + * + * @plexus.component role="org.apache.maven.wagon.Wagon" + * role-hint="ftps" + * instantiation-strategy="per-lookup" + */ +public class FtpsWagon +extends FtpWagon +{ +private static final Logger LOG = LoggerFactory.getLogger( FtpsWagon.class ); + +/** + * @plexus.configuration default-value="TLS" + */ +private String securityProtocol = "TLS"; + +/** + * @plexus.configuration default-value="false" + */ +private boolean implicit = false; + +/** + *
[5/7] maven-surefire git commit: Sure one test among JUnit 4 and JUnit 5
Sure one test among JUnit 4 and JUnit 5 Project: http://git-wip-us.apache.org/repos/asf/maven-surefire/repo Commit: http://git-wip-us.apache.org/repos/asf/maven-surefire/commit/a50c823b Tree: http://git-wip-us.apache.org/repos/asf/maven-surefire/tree/a50c823b Diff: http://git-wip-us.apache.org/repos/asf/maven-surefire/diff/a50c823b Branch: refs/heads/junit5 Commit: a50c823baba16f0bc5e4b7c08993d1bf706ce1dc Parents: 81f3dda Author: Benedikt RitterAuthored: Mon Oct 10 19:04:24 2016 +0200 Committer: Benedikt Ritter Committed: Sat Nov 19 14:02:17 2016 +0100 -- .../src/test/resources/junit4/pom.xml | 24 +--- .../junit4/src/test/java/junit5/JUnit5Test.java | 65 2 files changed, 81 insertions(+), 8 deletions(-) -- http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/a50c823b/surefire-integration-tests/src/test/resources/junit4/pom.xml -- diff --git a/surefire-integration-tests/src/test/resources/junit4/pom.xml b/surefire-integration-tests/src/test/resources/junit4/pom.xml index f277ceb..57e66b8 100644 --- a/surefire-integration-tests/src/test/resources/junit4/pom.xml +++ b/surefire-integration-tests/src/test/resources/junit4/pom.xml @@ -28,14 +28,28 @@ 1.0-SNAPSHOT Test for JUnit 4 + + + org.junit.jupiter + junit-jupiter-api + 5.0.0-M2 + + + junit + junit + 4.12 + test + + + org.apache.maven.plugins maven-compiler-plugin - ${java.version} - ${java.version} + 1.8 + 1.8 @@ -45,10 +59,6 @@ junit4 - -1.5 - - junit @@ -74,7 +84,6 @@ UTF-8 -1.8 5.0.0-M2 4.12.0-M2 1.0.0-M2 @@ -111,7 +120,6 @@ UTF-8 -1.8 1.0.0-M2 http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/a50c823b/surefire-integration-tests/src/test/resources/junit4/src/test/java/junit5/JUnit5Test.java -- diff --git a/surefire-integration-tests/src/test/resources/junit4/src/test/java/junit5/JUnit5Test.java b/surefire-integration-tests/src/test/resources/junit4/src/test/java/junit5/JUnit5Test.java new file mode 100644 index 000..558546d --- /dev/null +++ b/surefire-integration-tests/src/test/resources/junit4/src/test/java/junit5/JUnit5Test.java @@ -0,0 +1,65 @@ +package junit5; + +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +import org.junit.jupiter.api.AfterEach; +import org.junit.jupiter.api.AfterAll; +import org.junit.jupiter.api.Assertions; +import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Test; + + +/** + * A test using the JUnit 5 API, which should be executed by JUnit jupiter enigne + */ +public class JUnit5Test +{ + +private boolean setUpCalled; + +private static boolean tearDownCalled; + +@BeforeEach +public void setUp() +{ +setUpCalled = true; +System.out.println( "Called setUp" ); +} + +@AfterEach +public void tearDown() +{ +tearDownCalled = true; +System.out.println( "Called tearDown" ); +} + +@Test +public void testSetUp() +{ +Assertions.assertTrue( setUpCalled, "setUp was not called" ); +} + +@AfterAll +public static void oneTimeTearDown() +{ +Assertions.assertTrue( tearDownCalled, "tearDown was not called" ); +} + +}
[1/7] maven-surefire git commit: Remove unused property
Repository: maven-surefire Updated Branches: refs/heads/junit5 da9281412 -> e4a5247a7 Remove unused property Project: http://git-wip-us.apache.org/repos/asf/maven-surefire/repo Commit: http://git-wip-us.apache.org/repos/asf/maven-surefire/commit/108538ba Tree: http://git-wip-us.apache.org/repos/asf/maven-surefire/tree/108538ba Diff: http://git-wip-us.apache.org/repos/asf/maven-surefire/diff/108538ba Branch: refs/heads/junit5 Commit: 108538bae9fd5957aea47135f232ac2529167ff8 Parents: da92814 Author: Benedikt RitterAuthored: Sun Oct 9 14:30:49 2016 +0200 Committer: Benedikt Ritter Committed: Sat Nov 19 14:02:02 2016 +0100 -- surefire-integration-tests/src/test/resources/junit4/pom.xml | 5 - 1 file changed, 5 deletions(-) -- http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/108538ba/surefire-integration-tests/src/test/resources/junit4/pom.xml -- diff --git a/surefire-integration-tests/src/test/resources/junit4/pom.xml b/surefire-integration-tests/src/test/resources/junit4/pom.xml index 3d1f971..c10d8e9 100644 --- a/surefire-integration-tests/src/test/resources/junit4/pom.xml +++ b/surefire-integration-tests/src/test/resources/junit4/pom.xml @@ -28,11 +28,6 @@ 1.0-SNAPSHOT Test for JUnit 4 - - -4.4 - - junit
[7/7] maven-surefire git commit: Move engines into plugin declaration
Move engines into plugin declaration Project: http://git-wip-us.apache.org/repos/asf/maven-surefire/repo Commit: http://git-wip-us.apache.org/repos/asf/maven-surefire/commit/e4a5247a Tree: http://git-wip-us.apache.org/repos/asf/maven-surefire/tree/e4a5247a Diff: http://git-wip-us.apache.org/repos/asf/maven-surefire/diff/e4a5247a Branch: refs/heads/junit5 Commit: e4a5247a74ad95d4b79c074402c959414dfa2732 Parents: 31b5592 Author: Benedikt RitterAuthored: Tue Nov 22 21:16:37 2016 +0100 Committer: Benedikt Ritter Committed: Tue Nov 22 21:16:37 2016 +0100 -- .../maven/surefire/its/JUnit4VersionsIT.java| 10 +++ .../src/test/resources/junit4/pom.xml | 29 +++- 2 files changed, 15 insertions(+), 24 deletions(-) -- http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/e4a5247a/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java -- diff --git a/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java b/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java index 2df3b1c..3d8eb1b 100644 --- a/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java +++ b/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java @@ -88,11 +88,6 @@ public class JUnit4VersionsIT @Parameter public JUnitVersion version; -private SurefireLauncher unpack() -{ -return unpack( "/junit4", version.toString() ); -} - @Test public void testJunit() throws Exception @@ -106,4 +101,9 @@ public class JUnit4VersionsIT version.configure( unpack() ).executeTest().verifyErrorFree( 1 ); } +private SurefireLauncher unpack() +{ +return unpack( "/junit4", version.toString() ); +} + } http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/e4a5247a/surefire-integration-tests/src/test/resources/junit4/pom.xml -- diff --git a/surefire-integration-tests/src/test/resources/junit4/pom.xml b/surefire-integration-tests/src/test/resources/junit4/pom.xml index 57e66b8..f107e65 100644 --- a/surefire-integration-tests/src/test/resources/junit4/pom.xml +++ b/surefire-integration-tests/src/test/resources/junit4/pom.xml @@ -89,15 +89,6 @@ 1.0.0-M2 - - - org.junit.jupiter - junit-jupiter-engine - ${junit.jupiter.version} - test - - - @@ -109,6 +100,11 @@ junit-platform-surefire-provider ${junit.platform.version} + +org.junit.jupiter +junit-jupiter-engine +${junit.jupiter.version} + @@ -123,15 +119,6 @@ 1.0.0-M2 - - - org.junit.vintage - junit-vintage-engine - ${junit.version} - test - - - @@ -143,6 +130,11 @@ junit-platform-surefire-provider ${junit.platform.version} + +org.junit.vintage +junit-vintage-engine +${junit.version} + @@ -150,5 +142,4 @@ -
[4/7] maven-surefire git commit: Move share compiler configuration among projects
Move share compiler configuration among projects Project: http://git-wip-us.apache.org/repos/asf/maven-surefire/repo Commit: http://git-wip-us.apache.org/repos/asf/maven-surefire/commit/81f3dda5 Tree: http://git-wip-us.apache.org/repos/asf/maven-surefire/tree/81f3dda5 Diff: http://git-wip-us.apache.org/repos/asf/maven-surefire/diff/81f3dda5 Branch: refs/heads/junit5 Commit: 81f3dda52af9805a46bab2e608c62ed1b0e6b9fd Parents: 1ab033a Author: Benedikt RitterAuthored: Sun Oct 9 15:32:10 2016 +0200 Committer: Benedikt Ritter Committed: Sat Nov 19 14:02:13 2016 +0100 -- .../src/test/resources/junit4/pom.xml | 46 1 file changed, 18 insertions(+), 28 deletions(-) -- http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/81f3dda5/surefire-integration-tests/src/test/resources/junit4/pom.xml -- diff --git a/surefire-integration-tests/src/test/resources/junit4/pom.xml b/surefire-integration-tests/src/test/resources/junit4/pom.xml index d685f5b..f277ceb 100644 --- a/surefire-integration-tests/src/test/resources/junit4/pom.xml +++ b/surefire-integration-tests/src/test/resources/junit4/pom.xml @@ -28,9 +28,27 @@ 1.0-SNAPSHOT Test for JUnit 4 + + + +org.apache.maven.plugins +maven-compiler-plugin + + ${java.version} + ${java.version} + + + + + junit4 + + +1.5 + + junit @@ -44,14 +62,6 @@ org.apache.maven.plugins -maven-compiler-plugin - - 1.5 - 1.5 - - - -org.apache.maven.plugins maven-surefire-plugin ${surefire.version} @@ -77,24 +87,11 @@ ${junit.jupiter.version} test - - org.junit.vintage - junit-vintage-engine - ${junit.vintage.version} - test - -maven-compiler-plugin - - ${java.version} - ${java.version} - - - maven-surefire-plugin ${surefire.version} @@ -130,13 +127,6 @@ -maven-compiler-plugin - - ${java.version} - ${java.version} - - - maven-surefire-plugin ${surefire.version}
[6/7] maven-surefire git commit: Introduce JUnitVersion enum for configuring tests for different junit versions
Introduce JUnitVersion enum for configuring tests for different junit versions Project: http://git-wip-us.apache.org/repos/asf/maven-surefire/repo Commit: http://git-wip-us.apache.org/repos/asf/maven-surefire/commit/31b55924 Tree: http://git-wip-us.apache.org/repos/asf/maven-surefire/tree/31b55924 Diff: http://git-wip-us.apache.org/repos/asf/maven-surefire/diff/31b55924 Branch: refs/heads/junit5 Commit: 31b55924060c9b8994a28761c8d8722a6f1d491c Parents: a50c823 Author: Benedikt RitterAuthored: Mon Oct 10 19:27:26 2016 +0200 Committer: Benedikt Ritter Committed: Sat Nov 19 14:02:19 2016 +0100 -- .../maven/surefire/its/JUnit4VersionsIT.java| 92 +--- .../apache/maven/surefire/its/JUnitVersion.java | 78 + 2 files changed, 118 insertions(+), 52 deletions(-) -- http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/31b55924/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java -- diff --git a/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java b/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java index eb7e41e..2df3b1c 100644 --- a/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java +++ b/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java @@ -29,10 +29,26 @@ import org.junit.runner.RunWith; import org.junit.runners.Parameterized; import org.junit.runners.Parameterized.Parameter; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_10; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_11; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_12; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_8; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_8_1; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_8_2; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_9; import static org.junit.runners.Parameterized.*; -import static org.apache.commons.lang3.JavaVersion.JAVA_1_8; -import static org.apache.maven.surefire.its.fixture.HelperAssertions.assumeJavaVersion; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_0; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_1; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_2; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_3; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_3_1; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_4; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_5; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_6; +import static org.apache.maven.surefire.its.JUnitVersion.JUNIT_4_7; +import static org.apache.maven.surefire.its.JUnitVersion.JUPITER_5_0_0_M2; +import static org.apache.maven.surefire.its.JUnitVersion.VINTAGE_4_12_0_M2; /** * Basic suite test using all known versions of JUnit 4.x @@ -48,31 +64,33 @@ public class JUnit4VersionsIT public static Collection
[2/7] maven-surefire git commit: Reuse Junit4VersionsIT to also test JUnit 5
Reuse Junit4VersionsIT to also test JUnit 5 Project: http://git-wip-us.apache.org/repos/asf/maven-surefire/repo Commit: http://git-wip-us.apache.org/repos/asf/maven-surefire/commit/8995a289 Tree: http://git-wip-us.apache.org/repos/asf/maven-surefire/tree/8995a289 Diff: http://git-wip-us.apache.org/repos/asf/maven-surefire/diff/8995a289 Branch: refs/heads/junit5 Commit: 8995a2894488d6ca3796f274498b1516cd2ed131 Parents: 108538b Author: Benedikt RitterAuthored: Sun Oct 9 14:43:20 2016 +0200 Committer: Benedikt Ritter Committed: Sat Nov 19 14:02:07 2016 +0100 -- .../maven/surefire/its/JUnit4VersionsIT.java| 23 +++- .../src/test/resources/junit4/pom.xml | 108 ++- 2 files changed, 104 insertions(+), 27 deletions(-) -- http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/8995a289/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java -- diff --git a/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java b/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java index 8dd8f0c..bb216d3 100644 --- a/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java +++ b/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java @@ -31,6 +31,9 @@ import org.junit.runners.Parameterized.Parameter; import static org.junit.runners.Parameterized.*; +import static org.apache.commons.lang3.JavaVersion.JAVA_1_8; +import static org.apache.maven.surefire.its.fixture.HelperAssertions.assumeJavaVersion; + /** * Basic suite test using all known versions of JUnit 4.x * @@ -79,9 +82,27 @@ public class JUnit4VersionsIT runJUnitTest( version ); } +@Test +public void test500M2() +throws Exception +{ +assumeJavaVersion( JAVA_1_8 ); + +runJUnitTest( "5.0.0-M2" ); +} + public void runJUnitTest( String version ) throws Exception { -unpack().setJUnitVersion( version ).executeTest().verifyErrorFree( 1 ); +unpack().setJUnitVersion( version ).activateProfile( getProfile( version ) ).executeTest().verifyErrorFree( 1 ); +} + +private String getProfile( String version ) +{ +if ( version.startsWith( "4" ) ) +{ +return "junit4"; +} +return "junit5"; } } http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/8995a289/surefire-integration-tests/src/test/resources/junit4/pom.xml -- diff --git a/surefire-integration-tests/src/test/resources/junit4/pom.xml b/surefire-integration-tests/src/test/resources/junit4/pom.xml index c10d8e9..1dd57b0 100644 --- a/surefire-integration-tests/src/test/resources/junit4/pom.xml +++ b/surefire-integration-tests/src/test/resources/junit4/pom.xml @@ -28,31 +28,87 @@ 1.0-SNAPSHOT Test for JUnit 4 - - - junit - junit - ${junit.version} - test - - - - - - -org.apache.maven.plugins -maven-compiler-plugin - - 1.5 - 1.5 - - - -org.apache.maven.plugins -maven-surefire-plugin -${surefire.version} - - - + + + junit4 + + + junit + junit + ${junit.version} + test + + + + + + +org.apache.maven.plugins +maven-compiler-plugin + + 1.5 + 1.5 + + + +org.apache.maven.plugins +maven-surefire-plugin +${surefire.version} + + + + + + + junit5 + + +UTF-8 +1.8 +5.0.0-M2 +4.12.0-M2 +1.0.0-M2 + + + + + org.junit.jupiter + junit-jupiter-engine + ${junit.jupiter.version} + test + + + org.junit.vintage + junit-vintage-engine + ${junit.vintage.version} + test + + + + + + +maven-compiler-plugin + + ${java.version} + ${java.version} + + + +maven-surefire-plugin +${surefire.version} + + +org.junit.platform +junit-platform-surefire-provider +${junit.platform.version} + + + + + + + +
[3/7] maven-surefire git commit: Add test using vintage engine
Add test using vintage engine Project: http://git-wip-us.apache.org/repos/asf/maven-surefire/repo Commit: http://git-wip-us.apache.org/repos/asf/maven-surefire/commit/1ab033af Tree: http://git-wip-us.apache.org/repos/asf/maven-surefire/tree/1ab033af Diff: http://git-wip-us.apache.org/repos/asf/maven-surefire/diff/1ab033af Branch: refs/heads/junit5 Commit: 1ab033afb89c1646c64e4b95ed184179c1670c62 Parents: 8995a28 Author: Benedikt RitterAuthored: Sun Oct 9 14:51:55 2016 +0200 Committer: Benedikt Ritter Committed: Sat Nov 19 14:02:10 2016 +0100 -- .../maven/surefire/its/JUnit4VersionsIT.java| 19 +++-- .../src/test/resources/junit4/pom.xml | 44 +++- 2 files changed, 59 insertions(+), 4 deletions(-) -- http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/1ab033af/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java -- diff --git a/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java b/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java index bb216d3..eb7e41e 100644 --- a/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java +++ b/surefire-integration-tests/src/test/java/org/apache/maven/surefire/its/JUnit4VersionsIT.java @@ -83,6 +83,15 @@ public class JUnit4VersionsIT } @Test +public void test412M2() +throws Exception +{ +assumeJavaVersion( JAVA_1_8 ); + +runJUnitTest( "4.12.0-M2" ); +} + +@Test public void test500M2() throws Exception { @@ -99,10 +108,14 @@ public class JUnit4VersionsIT private String getProfile( String version ) { -if ( version.startsWith( "4" ) ) +if ( version.startsWith( "4.12" ) ) +{ +return "junit5-vintage"; +} +else if ( version.startsWith( "5" ) ) { -return "junit4"; +return "junit5-jupiter"; } -return "junit5"; +return "junit4"; } } http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/1ab033af/surefire-integration-tests/src/test/resources/junit4/pom.xml -- diff --git a/surefire-integration-tests/src/test/resources/junit4/pom.xml b/surefire-integration-tests/src/test/resources/junit4/pom.xml index 1dd57b0..d685f5b 100644 --- a/surefire-integration-tests/src/test/resources/junit4/pom.xml +++ b/surefire-integration-tests/src/test/resources/junit4/pom.xml @@ -60,7 +60,7 @@ - junit5 + junit5-jupiter UTF-8 @@ -108,6 +108,48 @@ + + + junit5-vintage + + +UTF-8 +1.8 +1.0.0-M2 + + + + + org.junit.vintage + junit-vintage-engine + ${junit.version} + test + + + + + + +maven-compiler-plugin + + ${java.version} + ${java.version} + + + +maven-surefire-plugin +${surefire.version} + + +org.junit.platform +junit-platform-surefire-provider +${junit.platform.version} + + + + + +
maven-surefire git commit: [SUREFIRE-1311] JUnit47 provider should not internally parse JUnit Description
Repository: maven-surefire Updated Branches: refs/heads/master c2a7d4b7f -> d9b577cdc [SUREFIRE-1311] JUnit47 provider should not internally parse JUnit Description Project: http://git-wip-us.apache.org/repos/asf/maven-surefire/repo Commit: http://git-wip-us.apache.org/repos/asf/maven-surefire/commit/d9b577cd Tree: http://git-wip-us.apache.org/repos/asf/maven-surefire/tree/d9b577cd Diff: http://git-wip-us.apache.org/repos/asf/maven-surefire/diff/d9b577cd Branch: refs/heads/master Commit: d9b577cdc991d09116282d89ca69b5d2768acb0e Parents: c2a7d4b Author: Tibor17Authored: Fri Dec 2 04:36:13 2016 +0100 Committer: Tibor17 Committed: Fri Dec 2 04:36:13 2016 +0100 -- .../common/junit4/JUnit4RunListener.java| 18 +++--- .../common/junit4/JUnit4StackTraceWriter.java | 14 ++- surefire-providers/common-junit48/pom.xml | 6 + .../common/junit48/JUnit46StackTraceWriter.java | 9 --- .../junitcore/JUnitCoreRunListener.java | 18 +++--- .../junitcore/NonConcurrentRunListener.java | 26 ++-- 6 files changed, 68 insertions(+), 23 deletions(-) -- http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/d9b577cd/surefire-providers/common-junit4/src/main/java/org/apache/maven/surefire/common/junit4/JUnit4RunListener.java -- diff --git a/surefire-providers/common-junit4/src/main/java/org/apache/maven/surefire/common/junit4/JUnit4RunListener.java b/surefire-providers/common-junit4/src/main/java/org/apache/maven/surefire/common/junit4/JUnit4RunListener.java index 85e2acd..dd004fa 100644 --- a/surefire-providers/common-junit4/src/main/java/org/apache/maven/surefire/common/junit4/JUnit4RunListener.java +++ b/surefire-providers/common-junit4/src/main/java/org/apache/maven/surefire/common/junit4/JUnit4RunListener.java @@ -120,7 +120,7 @@ public class JUnit4RunListener failureFlag.set( true ); } -@SuppressWarnings( { "UnusedDeclaration" } ) +@SuppressWarnings( "UnusedDeclaration" ) public void testAssumptionFailure( Failure failure ) { Description desc = failure.getDescription(); @@ -152,16 +152,16 @@ public class JUnit4RunListener reporter.testExecutionSkippedByUser(); } -private static String getClassName( Description description ) +private String getClassName( Description description ) { -String name = extractClassName( description ); +String name = extractDescriptionClassName( description ); if ( name == null || isInsaneJunitNullString( name ) ) { // This can happen upon early failures (class instantiation error etc) Description subDescription = description.getChildren().get( 0 ); if ( subDescription != null ) { -name = extractClassName( subDescription ); +name = extractDescriptionClassName( subDescription ); } if ( name == null ) { @@ -181,6 +181,16 @@ public class JUnit4RunListener return new SimpleReportEntry( getClassName( description ), description.getDisplayName() ); } +protected String extractDescriptionClassName( Description description ) +{ +return extractClassName( description ); +} + +protected String extractDescriptionMethodName( Description description ) +{ +return extractMethodName( description ); +} + public static String extractClassName( Description description ) { String displayName = description.getDisplayName(); http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/d9b577cd/surefire-providers/common-junit4/src/main/java/org/apache/maven/surefire/common/junit4/JUnit4StackTraceWriter.java -- diff --git a/surefire-providers/common-junit4/src/main/java/org/apache/maven/surefire/common/junit4/JUnit4StackTraceWriter.java b/surefire-providers/common-junit4/src/main/java/org/apache/maven/surefire/common/junit4/JUnit4StackTraceWriter.java index 8292d4b..a4690ca 100644 --- a/surefire-providers/common-junit4/src/main/java/org/apache/maven/surefire/common/junit4/JUnit4StackTraceWriter.java +++ b/surefire-providers/common-junit4/src/main/java/org/apache/maven/surefire/common/junit4/JUnit4StackTraceWriter.java @@ -22,9 +22,12 @@ package org.apache.maven.surefire.common.junit4; import org.apache.maven.surefire.report.SafeThrowable; import org.apache.maven.surefire.report.SmartStackTraceParser; import org.apache.maven.surefire.report.StackTraceWriter; - import org.junit.runner.notification.Failure; +import static org.apache.maven.surefire.common.junit4.JUnit4RunListener.extractClassName; +import static
maven-surefire git commit: [SUREFIRE-1305] surefire fails on parallel tests when newline character is in test description
Repository: maven-surefire Updated Branches: refs/heads/master 195e4833c -> c2a7d4b7f [SUREFIRE-1305] surefire fails on parallel tests when newline character is in test description Project: http://git-wip-us.apache.org/repos/asf/maven-surefire/repo Commit: http://git-wip-us.apache.org/repos/asf/maven-surefire/commit/c2a7d4b7 Tree: http://git-wip-us.apache.org/repos/asf/maven-surefire/tree/c2a7d4b7 Diff: http://git-wip-us.apache.org/repos/asf/maven-surefire/diff/c2a7d4b7 Branch: refs/heads/master Commit: c2a7d4b7f28b0fb5456b9871fd87cbac5c70cbd3 Parents: 195e483 Author: Tibor17Authored: Fri Dec 2 02:51:07 2016 +0100 Committer: Tibor17 Committed: Fri Dec 2 02:51:07 2016 +0100 -- .../maven/surefire/common/junit4/JUnit4RunListener.java | 10 +++--- 1 file changed, 3 insertions(+), 7 deletions(-) -- http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/c2a7d4b7/surefire-providers/common-junit4/src/main/java/org/apache/maven/surefire/common/junit4/JUnit4RunListener.java -- diff --git a/surefire-providers/common-junit4/src/main/java/org/apache/maven/surefire/common/junit4/JUnit4RunListener.java b/surefire-providers/common-junit4/src/main/java/org/apache/maven/surefire/common/junit4/JUnit4RunListener.java index d3aa9a4..85e2acd 100644 --- a/surefire-providers/common-junit4/src/main/java/org/apache/maven/surefire/common/junit4/JUnit4RunListener.java +++ b/surefire-providers/common-junit4/src/main/java/org/apache/maven/surefire/common/junit4/JUnit4RunListener.java @@ -44,11 +44,7 @@ import static org.apache.maven.surefire.report.SimpleReportEntry.withException; public class JUnit4RunListener extends org.junit.runner.notification.RunListener { -private static final Pattern PARENS = Pattern.compile( "^" + ".+" //any character - + "\\((" - // then an open-paren (start matching a group) - + "[^()]+" //non-parens - + ")\\)" + "$" ); +private static final Pattern METHOD_CLASS_PATTERN = Pattern.compile( "([\\s\\S]*)\\((.*)\\)" ); protected final RunListener reporter; @@ -188,8 +184,8 @@ public class JUnit4RunListener public static String extractClassName( Description description ) { String displayName = description.getDisplayName(); -Matcher m = PARENS.matcher( displayName ); -return m.find() ? m.group( 1 ) : displayName; +Matcher m = METHOD_CLASS_PATTERN.matcher( displayName ); +return m.matches() ? m.group( 2 ) : displayName; } public static String extractMethodName( Description description )
svn commit: r1772259 - /maven/shared/trunk/maven-dependency-tree/pom.xml
Author: rfscholte Date: Thu Dec 1 19:47:05 2016 New Revision: 1772259 URL: http://svn.apache.org/viewvc?rev=1772259=rev Log: Pass source+target to m-invoker-p, easiest way to override default values of maven-compiler-plugin Modified: maven/shared/trunk/maven-dependency-tree/pom.xml Modified: maven/shared/trunk/maven-dependency-tree/pom.xml URL: http://svn.apache.org/viewvc/maven/shared/trunk/maven-dependency-tree/pom.xml?rev=1772259=1772258=1772259=diff == --- maven/shared/trunk/maven-dependency-tree/pom.xml (original) +++ maven/shared/trunk/maven-dependency-tree/pom.xml Thu Dec 1 19:47:05 2016 @@ -154,6 +154,10 @@ reactor/pom.xml verbose/pom.xml + + ${maven.compiler.source} + ${maven.compiler.target} +
svn commit: r1772257 - in /maven/shared/trunk/maven-runtime: pom.xml src/test/java/org/apache/maven/shared/runtime/DefaultMavenRuntimeTest.java
Author: rfscholte Date: Thu Dec 1 19:39:41 2016 New Revision: 1772257 URL: http://svn.apache.org/viewvc?rev=1772257=rev Log: Make it possible to test project on Windows + M3.3.9 + Java9 Modified: maven/shared/trunk/maven-runtime/pom.xml maven/shared/trunk/maven-runtime/src/test/java/org/apache/maven/shared/runtime/DefaultMavenRuntimeTest.java Modified: maven/shared/trunk/maven-runtime/pom.xml URL: http://svn.apache.org/viewvc/maven/shared/trunk/maven-runtime/pom.xml?rev=1772257=1772256=1772257=diff == --- maven/shared/trunk/maven-runtime/pom.xml (original) +++ maven/shared/trunk/maven-runtime/pom.xml Thu Dec 1 19:39:41 2016 @@ -91,6 +91,12 @@ 3.2 test + + org.apache.maven.shared + maven-invoker + 2.2 + test + Modified: maven/shared/trunk/maven-runtime/src/test/java/org/apache/maven/shared/runtime/DefaultMavenRuntimeTest.java URL: http://svn.apache.org/viewvc/maven/shared/trunk/maven-runtime/src/test/java/org/apache/maven/shared/runtime/DefaultMavenRuntimeTest.java?rev=1772257=1772256=1772257=diff == --- maven/shared/trunk/maven-runtime/src/test/java/org/apache/maven/shared/runtime/DefaultMavenRuntimeTest.java (original) +++ maven/shared/trunk/maven-runtime/src/test/java/org/apache/maven/shared/runtime/DefaultMavenRuntimeTest.java Thu Dec 1 19:39:41 2016 @@ -670,6 +670,8 @@ public class DefaultMavenRuntimeTest ext File pom = getTestFile( "target/test-classes/", pomPath ); Properties properties = new Properties(); +properties.put( "maven.compiler.source", "1.6" ); +properties.put( "maven.compiler.target", "1.6" ); List goals = Arrays.asList( new String[] { "clean", "package" } ); File log = new File( pom.getParentFile(), "build.log" );