From commits-return-70074-archive-asf-public=cust-asf.ponee.io@maven.apache.org Mon Feb 5 23:07:22 2018 Return-Path: X-Original-To: archive-asf-public@eu.ponee.io Delivered-To: archive-asf-public@eu.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by mx-eu-01.ponee.io (Postfix) with ESMTP id DAAE4180677 for ; Mon, 5 Feb 2018 23:07:21 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id CA58E160C6A; Mon, 5 Feb 2018 22:07:21 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id E997D160C62 for ; Mon, 5 Feb 2018 23:07:18 +0100 (CET) Received: (qmail 57838 invoked by uid 500); 5 Feb 2018 22:07:16 -0000 Mailing-List: contact commits-help@maven.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@maven.apache.org Delivered-To: mailing list commits@maven.apache.org Received: (qmail 57070 invoked by uid 99); 5 Feb 2018 22:07:16 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 05 Feb 2018 22:07:16 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 8165DE96B8; Mon, 5 Feb 2018 22:07:15 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit From: tibordigana@apache.org To: commits@maven.apache.org Date: Mon, 05 Feb 2018 22:07:17 -0000 Message-Id: <40d8119656e7441f9d5351bf9732c9e0@git.apache.org> In-Reply-To: References: X-Mailer: ASF-Git Admin Mailer Subject: [04/51] [partial] maven-surefire git commit: [SUREFIRE-1471] Too long Windows path cause CI issues. Renamed surefire-intergation-tests to surefire-its. http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/pom.xml ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/pom.xml b/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/pom.xml new file mode 100644 index 0000000..4fb9d72 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/pom.xml @@ -0,0 +1,118 @@ + + + + 4.0.0 + + org.apache.maven.plugins.surefire + jiras-surefire-1202 + 1.0 + + http://maven.apache.org + + + + tibordigana + Tibor Digaňa (tibor17) + tibordigana@apache.org + + PMC + + Europe/Bratislava + + + + + 1.7 + 1.7 + + + + + junit + junit + 4.12 + test + + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + ${surefire.version} + + once + 1 + 2 + 3 + alphabetical + + + + + + + + + junit47 + + true + + + + + org.apache.maven.plugins + maven-surefire-plugin + + + org.apache.maven.surefire + surefire-junit47 + ${surefire.version} + + + + + + + + junit4 + + + + org.apache.maven.plugins + maven-surefire-plugin + + + org.apache.maven.surefire + surefire-junit4 + ${surefire.version} + + + + + + + + + \ No newline at end of file http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/ATest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/ATest.java b/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/ATest.java new file mode 100644 index 0000000..cbe3f6f --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/ATest.java @@ -0,0 +1,45 @@ +package pkg; + +/* + * 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.Test; + +import static java.util.concurrent.TimeUnit.MILLISECONDS; +import static java.util.concurrent.TimeUnit.SECONDS; + +public class ATest +{ + private static int count; + + @Test + public void testA() + throws Exception + { + MILLISECONDS.sleep( 500 ); + if ( count++ != 2 ) + { + throw new RuntimeException( "assert \"foo\" == \"bar\"\n" + + " |\n" + + " false" + ); + } + SECONDS.sleep( 5 ); + } +} \ No newline at end of file http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/BTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/BTest.java b/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/BTest.java new file mode 100644 index 0000000..f44d396 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/BTest.java @@ -0,0 +1,42 @@ +package pkg; + +/* + * 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.Test; + +import static java.util.concurrent.TimeUnit.SECONDS; + +public class BTest +{ + + private static int count; + + @Test + public void testB() + throws InterruptedException + { + SECONDS.sleep( 2 ); + if ( count++ != 2 ) + { + throw new RuntimeException(); + } + } + +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/CTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/CTest.java b/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/CTest.java new file mode 100644 index 0000000..e51a29d --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/CTest.java @@ -0,0 +1,35 @@ +package pkg; + +/* + * 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.Test; + +import static java.util.concurrent.TimeUnit.MILLISECONDS; + +public class CTest +{ + @Test + public void testC() + throws InterruptedException + { + MILLISECONDS.sleep( 500 ); + } + +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/DTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/DTest.java b/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/DTest.java new file mode 100644 index 0000000..85bc666 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/DTest.java @@ -0,0 +1,35 @@ +package pkg; + +/* + * 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.Test; + +import static java.util.concurrent.TimeUnit.MILLISECONDS; + +public class DTest +{ + @Test + public void testD() + throws InterruptedException + { + MILLISECONDS.sleep( 500 ); + } + +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/ETest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/ETest.java b/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/ETest.java new file mode 100644 index 0000000..a74e734 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1202-rerun-and-failfast/src/test/java/pkg/ETest.java @@ -0,0 +1,31 @@ +package pkg; + +/* + * 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.Test; + +public class ETest +{ + @Test + public void test() + throws InterruptedException + { + } +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/pom.xml ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/pom.xml b/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/pom.xml new file mode 100644 index 0000000..9bb5c27 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/pom.xml @@ -0,0 +1,115 @@ + + + + 4.0.0 + + org.apache.maven.plugins.surefire + jiras-surefire-1209 + 1.0 + + http://maven.apache.org + + + + tibordigana + Tibor Digaňa (tibor17) + tibordigana@apache.org + + PMC + + Europe/Bratislava + + + + + 1.7 + 1.7 + + + + + junit + junit + 4.12 + test + + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + ${surefire.version} + + 2 + 3 + + + + + + + + + junit47 + + true + + + + + org.apache.maven.plugins + maven-surefire-plugin + + + org.apache.maven.surefire + surefire-junit47 + ${surefire.version} + + + + + + + + junit4 + + + + org.apache.maven.plugins + maven-surefire-plugin + + + org.apache.maven.surefire + surefire-junit4 + ${surefire.version} + + + + + + + + + \ No newline at end of file http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/ATest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/ATest.java b/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/ATest.java new file mode 100644 index 0000000..cbe3f6f --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/ATest.java @@ -0,0 +1,45 @@ +package pkg; + +/* + * 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.Test; + +import static java.util.concurrent.TimeUnit.MILLISECONDS; +import static java.util.concurrent.TimeUnit.SECONDS; + +public class ATest +{ + private static int count; + + @Test + public void testA() + throws Exception + { + MILLISECONDS.sleep( 500 ); + if ( count++ != 2 ) + { + throw new RuntimeException( "assert \"foo\" == \"bar\"\n" + + " |\n" + + " false" + ); + } + SECONDS.sleep( 5 ); + } +} \ No newline at end of file http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/BTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/BTest.java b/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/BTest.java new file mode 100644 index 0000000..f44d396 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/BTest.java @@ -0,0 +1,42 @@ +package pkg; + +/* + * 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.Test; + +import static java.util.concurrent.TimeUnit.SECONDS; + +public class BTest +{ + + private static int count; + + @Test + public void testB() + throws InterruptedException + { + SECONDS.sleep( 2 ); + if ( count++ != 2 ) + { + throw new RuntimeException(); + } + } + +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/CTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/CTest.java b/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/CTest.java new file mode 100644 index 0000000..e51a29d --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/CTest.java @@ -0,0 +1,35 @@ +package pkg; + +/* + * 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.Test; + +import static java.util.concurrent.TimeUnit.MILLISECONDS; + +public class CTest +{ + @Test + public void testC() + throws InterruptedException + { + MILLISECONDS.sleep( 500 ); + } + +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/DTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/DTest.java b/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/DTest.java new file mode 100644 index 0000000..85bc666 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/DTest.java @@ -0,0 +1,35 @@ +package pkg; + +/* + * 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.Test; + +import static java.util.concurrent.TimeUnit.MILLISECONDS; + +public class DTest +{ + @Test + public void testD() + throws InterruptedException + { + MILLISECONDS.sleep( 500 ); + } + +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/ETest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/ETest.java b/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/ETest.java new file mode 100644 index 0000000..a74e734 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1209-rerun-and-forkcount/src/test/java/pkg/ETest.java @@ -0,0 +1,31 @@ +package pkg; + +/* + * 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.Test; + +public class ETest +{ + @Test + public void test() + throws InterruptedException + { + } +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1211/pom.xml ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1211/pom.xml b/surefire-its/src/test/resources/surefire-1211/pom.xml new file mode 100644 index 0000000..98db2a7 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1211/pom.xml @@ -0,0 +1,71 @@ + + + + + 4.0.0 + + + org.apache.maven.surefire + it-parent + 1.0 + + + org.apache.maven.plugins.surefire + surefire-1211 + 1.0 + + + + + + + + org.testng + testng + 6.9.4 + + + junit + junit + 4.10 + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + + once + + + junit + ${junit} + + + + + + + + http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1211/src/test/java/jira1211/JUnitTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1211/src/test/java/jira1211/JUnitTest.java b/surefire-its/src/test/resources/surefire-1211/src/test/java/jira1211/JUnitTest.java new file mode 100644 index 0000000..1580e8a --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1211/src/test/java/jira1211/JUnitTest.java @@ -0,0 +1,31 @@ +package jira1211; + +/* + * 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.Test; + +public class JUnitTest { + + @Test + public void doNothing() + { + + } +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1211/src/test/java/jira1211/TestNGSuiteTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1211/src/test/java/jira1211/TestNGSuiteTest.java b/surefire-its/src/test/resources/surefire-1211/src/test/java/jira1211/TestNGSuiteTest.java new file mode 100644 index 0000000..46959c7 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1211/src/test/java/jira1211/TestNGSuiteTest.java @@ -0,0 +1,32 @@ +package jira1211; + +/* + * 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.testng.annotations.Test; + + +public class TestNGSuiteTest { + + @Test + public void doNothing() + { + + } +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1260-new-tests-pattern/pom.xml ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1260-new-tests-pattern/pom.xml b/surefire-its/src/test/resources/surefire-1260-new-tests-pattern/pom.xml new file mode 100644 index 0000000..5f3df66 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1260-new-tests-pattern/pom.xml @@ -0,0 +1,60 @@ + + + + + 4.0.0 + + + + org.apache.maven.surefire + it-parent + 1.0 + ../pom.xml + + + org.apache.maven.plugins.surefire + surefire-1260 + 1.0 + + http://maven.apache.org + + + + tibordigana + Tibor Diga??a (tibor17) + tibordigana@apache.org + + PMC + + Europe/Bratislava + + + + + + junit + junit + 4.0 + test + + + http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1260-new-tests-pattern/src/test/java/pkg/JUnit3Tests.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1260-new-tests-pattern/src/test/java/pkg/JUnit3Tests.java b/surefire-its/src/test/resources/surefire-1260-new-tests-pattern/src/test/java/pkg/JUnit3Tests.java new file mode 100644 index 0000000..d607a3b --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1260-new-tests-pattern/src/test/java/pkg/JUnit3Tests.java @@ -0,0 +1,34 @@ +package pkg; + +/* + * 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 junit.framework.TestCase; + +public class JUnit3Tests extends TestCase +{ + public void test1() + { + } + + public void test2() + { + } + +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1260-new-tests-pattern/src/test/java/pkg/JUnit4Tests.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1260-new-tests-pattern/src/test/java/pkg/JUnit4Tests.java b/surefire-its/src/test/resources/surefire-1260-new-tests-pattern/src/test/java/pkg/JUnit4Tests.java new file mode 100644 index 0000000..f34aee7 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1260-new-tests-pattern/src/test/java/pkg/JUnit4Tests.java @@ -0,0 +1,42 @@ +package pkg; + +/* + * 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.Test; + +public class JUnit4Tests +{ + + @Test + public void shouldTestA() + { + } + + @Test + public void shouldTestB() + { + } + + @Test + public void shouldTestC() + { + } + +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1264/pom.xml ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1264/pom.xml b/surefire-its/src/test/resources/surefire-1264/pom.xml new file mode 100644 index 0000000..320401d --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1264/pom.xml @@ -0,0 +1,52 @@ + + + 4.0.0 + + + org.apache.maven.surefire + it-parent + 1.0 + ../pom.xml + + + com.appnexus.viewability.core.surefireJunitTests + main + 1.0.0 + + + + + + org.apache.maven.plugins + maven-surefire-plugin + ${surefire.version} + + 2 + all + balanced + once + + ${canFail} + + + + + org.apache.maven.surefire + surefire-junit47 + ${surefire.version} + + + + + + + + + + junit + junit + 4.12 + test + + + http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/ATest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/ATest.java b/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/ATest.java new file mode 100644 index 0000000..18c129e --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/ATest.java @@ -0,0 +1,33 @@ +package com.appnexus.viewability.core.surefireJunitTests; + +import org.junit.Assert; +import org.junit.Test; + +public class ATest + extends BaseTest +{ + public ATest( String param ) + { + super( param ); + } + + @Test + public void methodA1() throws InterruptedException + { + sleep( 10 ); + if ( Boolean.getBoolean( "canFail" ) ) + { + Assert.fail( "Failing test: ATest.methodA1[" + param + "]" ); + } + } + + @Test + public void methodA2() throws InterruptedException + { + sleep( 10 ); + if ( Boolean.getBoolean( "canFail" ) ) + { + Assert.fail( "Failing test: ATest.methodA2[" + param + "]" ); + } + } +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/BTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/BTest.java b/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/BTest.java new file mode 100644 index 0000000..3ebf05c --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/BTest.java @@ -0,0 +1,33 @@ +package com.appnexus.viewability.core.surefireJunitTests; + +import org.junit.Assert; +import org.junit.Test; + +public class BTest + extends BaseTest +{ + public BTest( String param ) + { + super( param ); + } + + @Test + public void methodB1() throws InterruptedException + { + sleep( 10 ); + if ( Boolean.getBoolean( "canFail" ) ) + { + Assert.fail( "Failing test: BTest.methodB1[" + param + "]" ); + } + } + + @Test + public void methodB2() throws InterruptedException + { + sleep( 10 ); + if ( Boolean.getBoolean( "canFail" ) ) + { + Assert.fail( "Failing test: BTest.methodB2[" + param + "]" ); + } + } +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/BaseTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/BaseTest.java b/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/BaseTest.java new file mode 100644 index 0000000..bff4077 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/BaseTest.java @@ -0,0 +1,52 @@ +package com.appnexus.viewability.core.surefireJunitTests; + +import java.util.concurrent.ConcurrentLinkedQueue; +import java.util.Collection; + +import org.junit.Rule; +import org.junit.rules.TestName; +import org.junit.runner.RunWith; + + +import org.junit.runners.Parameterized; +import org.junit.runners.Parameterized.Parameters; + + +@RunWith( Parameterized.class ) +public abstract class BaseTest +{ + protected final String param; + + public BaseTest( String param ) + { + this.param = param; + } + + @Rule + public TestName testName = new TestName(); + + @Parameters( name = "{0}" ) + public static Collection< String > parameterList() throws Exception + { + Collection< String > c = new ConcurrentLinkedQueue< String >(); + c.add( "p0" ); + c.add( "p1" ); + + return c; + } + + public void sleep( int time ) + { + System.err.println( "Start: " + this.getClass().getSimpleName() + "." + testName.getMethodName() ); + try + { + Thread.sleep( time * 100 ); + } + catch ( InterruptedException e ) + { + // TODO Auto-generated catch block + e.printStackTrace(); + } + System.err.println( "End: " + this.getClass().getSimpleName() + "." + testName.getMethodName() ); + } +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/CTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/CTest.java b/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/CTest.java new file mode 100644 index 0000000..3adb4ab --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/CTest.java @@ -0,0 +1,33 @@ +package com.appnexus.viewability.core.surefireJunitTests; + +import org.junit.Assert; +import org.junit.Test; + +public class CTest + extends BaseTest +{ + public CTest( String param ) + { + super( param ); + } + + @Test + public void methodC1() throws InterruptedException + { + sleep( 1 ); + if ( Boolean.getBoolean( "canFail" ) ) + { + Assert.fail( "Failing test: CTest.methodC1[" + param + "]" ); + } + } + + @Test + public void methodC2() throws InterruptedException + { + sleep( 1 ); + if ( Boolean.getBoolean( "canFail" ) ) + { + Assert.fail( "Failing test: CTest.methodC2[" + param + "]" ); + } + } +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/DTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/DTest.java b/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/DTest.java new file mode 100644 index 0000000..38ed7b7 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1264/src/test/java/com/appnexus/viewability/core/surefireJunitTests/DTest.java @@ -0,0 +1,33 @@ +package com.appnexus.viewability.core.surefireJunitTests; + +import org.junit.Assert; +import org.junit.Test; + +public class DTest + extends BaseTest +{ + public DTest( String param ) + { + super( param ); + } + + @Test + public void methodC1() throws InterruptedException + { + sleep( 1 ); + if ( Boolean.getBoolean( "canFail" ) ) + { + Assert.fail( "Failing test: DTest.methodD1[" + param + "]" ); + } + } + + @Test + public void methodC2() throws InterruptedException + { + sleep( 1 ); + if ( Boolean.getBoolean( "canFail" ) ) + { + Assert.fail( "Failing test: DTest.methodD2[" + param + "]" ); + } + } +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1265/pom.xml ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1265/pom.xml b/surefire-its/src/test/resources/surefire-1265/pom.xml new file mode 100644 index 0000000..ec74a49 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1265/pom.xml @@ -0,0 +1,49 @@ + + + + + 4.0.0 + + + org.apache.maven.surefire + it-parent + 1.0 + + + org.apache.maven.plugins.surefire + surefire-1265 + 1.0 + + + UTF-8 + 9 + 9 + + + + + junit + junit + 4.12 + test + + + http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1265/src/test/java/J9Test.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1265/src/test/java/J9Test.java b/surefire-its/src/test/resources/surefire-1265/src/test/java/J9Test.java new file mode 100644 index 0000000..3d41aea --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1265/src/test/java/J9Test.java @@ -0,0 +1,15 @@ +import org.junit.Test; + +public class J9Test +{ + @Test + public void test_sql_mod() throws java.sql.SQLException + { + System.out.println( System.getProperty( "java.specification.version" ) ); + } + + @Test + public void test_corba_mod() /*throws org.omg.CORBA.BAD_INV_ORDER*/ + { + } +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1278-group-name-ending/pom.xml ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1278-group-name-ending/pom.xml b/surefire-its/src/test/resources/surefire-1278-group-name-ending/pom.xml new file mode 100644 index 0000000..d262525 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1278-group-name-ending/pom.xml @@ -0,0 +1,58 @@ + + + + + 4.0.0 + + org.apache.maven.plugins.surefire + jiras-surefire-1278 + 1.0-SNAPSHOT + Test for testng groups + + + 1.7 + 1.7 + + + + + org.testng + testng + 6.8.7 + test + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + ${surefire.version} + + group + + + + + + http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1278-group-name-ending/src/test/java/pkg/ATest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1278-group-name-ending/src/test/java/pkg/ATest.java b/surefire-its/src/test/resources/surefire-1278-group-name-ending/src/test/java/pkg/ATest.java new file mode 100644 index 0000000..28c7e30 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1278-group-name-ending/src/test/java/pkg/ATest.java @@ -0,0 +1,40 @@ +package pkg; + +/* + * 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.testng.Assert; +import org.testng.annotations.Test; + +/** + * Tests grouping + */ +public class ATest +{ + @Test(groups = {"group"}) + public void group() + { + } + + @Test(groups = {"agroup"}) + public void agroup() + { + Assert.fail("Group should not be run"); + } +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1364/pom.xml ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1364/pom.xml b/surefire-its/src/test/resources/surefire-1364/pom.xml new file mode 100644 index 0000000..952ca06 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1364/pom.xml @@ -0,0 +1,155 @@ + + + + + 4.0.0 + + + org.apache.maven.surefire + it-parent + 1.0 + + + org.apache.maven.plugins.surefire + surefire-1364 + 1.0 + + + UTF-8 + once + + + + + junit + junit + 4.12 + test + + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + 3.7.0 + + + FirstTest.java + SecondTest.java + + + + + org.apache.maven.plugins + maven-surefire-plugin + + ${forkedMode} + + forkedValue${surefire.forkNumber} + + + + + + + + + junit3 + + + + + org.apache.maven.plugins + maven-surefire-plugin + + + org.apache.maven.surefire + surefire-junit3 + ${surefire.version} + + + + + + + + + junit47 + + + + + org.apache.maven.plugins + maven-surefire-plugin + + + org.apache.maven.surefire + surefire-junit47 + ${surefire.version} + + + + + + + + + testng + + + org.testng + testng + 6.8.21 + test + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + + + *.java + + + + + org.apache.maven.plugins + maven-surefire-plugin + + + org.apache.maven.surefire + surefire-testng + ${surefire.version} + + + + + + + + + http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1364/src/test/java/FirstTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1364/src/test/java/FirstTest.java b/surefire-its/src/test/resources/surefire-1364/src/test/java/FirstTest.java new file mode 100644 index 0000000..f2a9e66 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1364/src/test/java/FirstTest.java @@ -0,0 +1,30 @@ +/* + * 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 junit.framework.TestCase; +import org.junit.Test; + +public class FirstTest extends TestCase +{ + @Test + public void test() throws InterruptedException + { + Thread.sleep( 100 ); + } +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1364/src/test/java/SecondTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1364/src/test/java/SecondTest.java b/surefire-its/src/test/resources/surefire-1364/src/test/java/SecondTest.java new file mode 100644 index 0000000..cfd9b51 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1364/src/test/java/SecondTest.java @@ -0,0 +1,30 @@ +/* + * 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 junit.framework.TestCase; +import org.junit.Test; + +public class SecondTest extends TestCase +{ + @Test + public void test() throws InterruptedException + { + Thread.sleep( 100 ); + } +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1364/src/test/java/ThirdTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1364/src/test/java/ThirdTest.java b/surefire-its/src/test/resources/surefire-1364/src/test/java/ThirdTest.java new file mode 100644 index 0000000..f3633d6 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1364/src/test/java/ThirdTest.java @@ -0,0 +1,30 @@ +/* + * 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.testng.annotations.Test; + + +public class ThirdTest +{ + @Test + public void test() throws InterruptedException + { + Thread.sleep( 100 ); + } +} \ No newline at end of file http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1367/pom.xml ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1367/pom.xml b/surefire-its/src/test/resources/surefire-1367/pom.xml new file mode 100644 index 0000000..b1d3ac3 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1367/pom.xml @@ -0,0 +1,59 @@ + + + + 4.0.0 + + + org.apache.maven.surefire + it-parent + 1.0 + ../pom.xml + + + org.apache.maven.plugins.surefire + surefire-1367 + 1.0 + + + UTF-8 + + + + + junit + junit + 4.12 + test + + + + + + + maven-surefire-plugin + + ${forkMode} + true + + + + + http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1367/src/test/java/ATest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1367/src/test/java/ATest.java b/surefire-its/src/test/resources/surefire-1367/src/test/java/ATest.java new file mode 100644 index 0000000..df5231e --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1367/src/test/java/ATest.java @@ -0,0 +1,38 @@ +/* + * 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.Test; + +import static org.junit.Assume.assumeTrue; + +public class ATest { + + @Test + public void test() { + System.out.println("Hi"); + System.out.println(); + System.out.println("There!"); + + System.err.println("Hello"); + System.err.println(); + System.err.println("What's up!"); + + assumeTrue( false ); + } +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1367/src/test/java/BTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1367/src/test/java/BTest.java b/surefire-its/src/test/resources/surefire-1367/src/test/java/BTest.java new file mode 100644 index 0000000..bec4da8 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1367/src/test/java/BTest.java @@ -0,0 +1,34 @@ +/* + * 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.Test; + +import static org.junit.Assume.assumeTrue; + +public class BTest { + + @Test + public void test() { + System.out.println("Hey"); + System.out.println(); + System.out.println("you!"); + + assumeTrue( false ); + } +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath-provider/pom.xml ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath-provider/pom.xml b/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath-provider/pom.xml new file mode 100644 index 0000000..30e5199 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath-provider/pom.xml @@ -0,0 +1,52 @@ + + + + 4.0.0 + + org.apache.maven.plugins.surefire + surefire-test-classpath-provider + 1.0-SNAPSHOT + Test provider + + + 1.7 + 1.7 + + + + + org.apache.maven.surefire + surefire-api + ${surefire.version} + + + + + + + src/main/resources/META-INF + META-INF + + + + + + http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath-provider/src/main/java/org/apache/maven/surefire/testprovider/ClassPathTestProvider.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath-provider/src/main/java/org/apache/maven/surefire/testprovider/ClassPathTestProvider.java b/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath-provider/src/main/java/org/apache/maven/surefire/testprovider/ClassPathTestProvider.java new file mode 100644 index 0000000..eeea397 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath-provider/src/main/java/org/apache/maven/surefire/testprovider/ClassPathTestProvider.java @@ -0,0 +1,63 @@ +package org.apache.maven.surefire.testprovider; + +/* + * 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 java.lang.reflect.InvocationTargetException; +import java.util.LinkedList; +import java.util.Map.Entry; + +import org.apache.maven.surefire.providerapi.AbstractProvider; +import org.apache.maven.surefire.providerapi.ProviderParameters; +import org.apache.maven.surefire.report.ReporterException; +import org.apache.maven.surefire.suite.RunResult; +import org.apache.maven.surefire.testset.TestSetFailedException; + +/** + * @author Jonathan Bell + */ +public class ClassPathTestProvider + extends AbstractProvider +{ + boolean hasSLF4J; // SLF4J is not being included in our deps, so if it's in the classpath, that's a problem... + + public ClassPathTestProvider( ProviderParameters params ) + { + for ( Entry propEntry : params.getProviderProperties().entrySet() ) + { + if ( propEntry.getKey().startsWith( "surefireClassPathUrl" ) && propEntry.getValue().contains( "slf4j" ) ) + hasSLF4J = true; + } + } + + public Iterable> getSuites() + { + LinkedList> ret = new LinkedList>(); + return ret; + } + + public RunResult invoke( Object arg0 ) + throws TestSetFailedException, ReporterException, InvocationTargetException + { + if ( hasSLF4J ) + throw new TestSetFailedException( "SLF4J was found on the boot classpath" ); + return new RunResult( 1, 0, 0, 0 ); + } + +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath-provider/src/main/resources/META-INF/services/org.apache.maven.surefire.providerapi.SurefireProvider ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath-provider/src/main/resources/META-INF/services/org.apache.maven.surefire.providerapi.SurefireProvider b/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath-provider/src/main/resources/META-INF/services/org.apache.maven.surefire.providerapi.SurefireProvider new file mode 100644 index 0000000..fd31063 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath-provider/src/main/resources/META-INF/services/org.apache.maven.surefire.providerapi.SurefireProvider @@ -0,0 +1 @@ +org.apache.maven.surefire.testprovider.ClassPathTestProvider http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath/pom.xml ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath/pom.xml b/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath/pom.xml new file mode 100644 index 0000000..be5cf97 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath/pom.xml @@ -0,0 +1,82 @@ + + + + + 4.0.0 + + org.apache.maven.plugins.surefire + pluggableproviders-classpath + 1.0-SNAPSHOT + pluggableproviders-classpath-test + + + 1.7 + 1.7 + + + + + junit + junit + 4.8.1 + test + + + + + + + org.apache.maven.plugins + maven-surefire-plugin + ${surefire.version} + + + org.apache.maven.plugins.surefire + surefire-test-classpath-provider + 1.0-SNAPSHOT + + + + + org.apache.maven.plugins + maven-failsafe-plugin + ${surefire.version} + + + + integration-test + verify + + + + + + org.apache.maven.plugins.surefire + surefire-test-classpath-provider + 1.0-SNAPSHOT + + + + + + + http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath/src/test/java/pluggableproviders/EmptyIT.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath/src/test/java/pluggableproviders/EmptyIT.java b/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath/src/test/java/pluggableproviders/EmptyIT.java new file mode 100644 index 0000000..f7e2a7f --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath/src/test/java/pluggableproviders/EmptyIT.java @@ -0,0 +1,26 @@ +package pluggableproviders; + +/* + * 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. + */ + + +public class EmptyIT +{ + +} http://git-wip-us.apache.org/repos/asf/maven-surefire/blob/09f0eef8/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath/src/test/java/pluggableproviders/EmptyTest.java ---------------------------------------------------------------------- diff --git a/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath/src/test/java/pluggableproviders/EmptyTest.java b/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath/src/test/java/pluggableproviders/EmptyTest.java new file mode 100644 index 0000000..4ac75c7 --- /dev/null +++ b/surefire-its/src/test/resources/surefire-1396-pluggableproviders-classpath/src/test/java/pluggableproviders/EmptyTest.java @@ -0,0 +1,26 @@ +package pluggableproviders; + +/* + * 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. + */ + + +public class EmptyTest +{ + +}