From 45dd65a58e38cfe64cf392ef523afdab6dd04fe5 Mon Sep 17 00:00:00 2001 From: Dennis Hendriks Date: Sun, 13 Aug 2023 17:02:18 +0200 Subject: [PATCH] tycho-its reproducer p2Repository.downloadVerifyNoDigestAlgo (#2710) --- .../pom.xml | 82 +++++++++++++++++++ .../test.feature/build.properties | 2 + .../test.feature/extra.txt | 1 + .../test.feature/feature.xml | 16 ++++ .../test.feature/pom.xml | 16 ++++ .../test.product/category.xml | 2 + .../test.product/pom.xml | 31 +++++++ .../test.product/test.product | 17 ++++ .../test.target/pom.xml | 15 ++++ .../test.target/test.target | 37 +++++++++ .../DownloadVerifyNoDigestAlgoTest.java | 25 ++++++ 11 files changed, 244 insertions(+) create mode 100644 tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/pom.xml create mode 100644 tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/build.properties create mode 100644 tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/extra.txt create mode 100644 tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/feature.xml create mode 100644 tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/pom.xml create mode 100644 tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.product/category.xml create mode 100644 tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.product/pom.xml create mode 100644 tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.product/test.product create mode 100644 tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.target/pom.xml create mode 100644 tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.target/test.target create mode 100644 tycho-its/src/test/java/org/eclipse/tycho/test/p2Repository/DownloadVerifyNoDigestAlgoTest.java diff --git a/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/pom.xml b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/pom.xml new file mode 100644 index 0000000000..46278f2207 --- /dev/null +++ b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/pom.xml @@ -0,0 +1,82 @@ + + + 4.0.0 + + tycho-its-project.p2Repository.downloadVerifyNoDigestAlgo + tycho-its-project.p2Repository.downloadVerifyNoDigestAlgo.root + 1.0.0-SNAPSHOT + + pom + + + test.feature + test.product + test.target + + + + + + org.eclipse.tycho + tycho-maven-plugin + ${tycho-version} + true + + + org.eclipse.tycho + tycho-compiler-plugin + ${tycho-version} + + + org.eclipse.tycho + tycho-packaging-plugin + ${tycho-version} + + + org.eclipse.tycho + target-platform-configuration + ${tycho-version} + + + + tycho-its-project.p2Repository.downloadVerifyNoDigestAlgo + tycho-its-project.p2Repository.downloadVerifyNoDigestAlgo.target + 1.0.0-SNAPSHOT + + + org.eclipse.justj.openjdk.hotspot.jre.full-17 + + + linux + gtk + x86_64 + + + consider + + + + org.eclipse.tycho + tycho-p2-plugin + ${tycho-version} + + + default-p2-metadata-default + + false + + + + attach-p2-metadata + package + + p2-metadata + + + + + + + + diff --git a/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/build.properties b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/build.properties new file mode 100644 index 0000000000..28874d8ee4 --- /dev/null +++ b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/build.properties @@ -0,0 +1,2 @@ +bin.includes=feature.xml +root=file:extra.txt diff --git a/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/extra.txt b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/extra.txt new file mode 100644 index 0000000000..747e5336cf --- /dev/null +++ b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/extra.txt @@ -0,0 +1 @@ +Intentionally empty file. diff --git a/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/feature.xml b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/feature.xml new file mode 100644 index 0000000000..cb22aa4dc7 --- /dev/null +++ b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/feature.xml @@ -0,0 +1,16 @@ + + + + + + + + + + + + + diff --git a/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/pom.xml b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/pom.xml new file mode 100644 index 0000000000..58ec730e97 --- /dev/null +++ b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.feature/pom.xml @@ -0,0 +1,16 @@ + + + 4.0.0 + + + tycho-its-project.p2Repository.downloadVerifyNoDigestAlgo + tycho-its-project.p2Repository.downloadVerifyNoDigestAlgo.root + 1.0.0-SNAPSHOT + .. + + + tycho-its-project.p2Repository.downloadVerifyNoDigestAlgo.feature + eclipse-feature + + diff --git a/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.product/category.xml b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.product/category.xml new file mode 100644 index 0000000000..8cfa259357 --- /dev/null +++ b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.product/category.xml @@ -0,0 +1,2 @@ + + diff --git a/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.product/pom.xml b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.product/pom.xml new file mode 100644 index 0000000000..f9d929894c --- /dev/null +++ b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.product/pom.xml @@ -0,0 +1,31 @@ + + + 4.0.0 + + + tycho-its-project.p2Repository.downloadVerifyNoDigestAlgo + tycho-its-project.p2Repository.downloadVerifyNoDigestAlgo.root + 1.0.0-SNAPSHOT + .. + + + tycho-its-project.p2Repository.downloadVerifyNoDigestAlgo.product + eclipse-repository + + + + + org.eclipse.tycho + tycho-p2-repository-plugin + ${tycho-version} + + + org.eclipse.tycho + tycho-p2-director-plugin + ${tycho-version} + + + + + diff --git a/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.product/test.product b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.product/test.product new file mode 100644 index 0000000000..9410cb6ebf --- /dev/null +++ b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.product/test.product @@ -0,0 +1,17 @@ + + + + + + + + + + + + + + + + + diff --git a/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.target/pom.xml b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.target/pom.xml new file mode 100644 index 0000000000..80e90d4214 --- /dev/null +++ b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.target/pom.xml @@ -0,0 +1,15 @@ + + + 4.0.0 + + + tycho-its-project.p2Repository.downloadVerifyNoDigestAlgo + tycho-its-project.p2Repository.downloadVerifyNoDigestAlgo.root + 1.0.0-SNAPSHOT + .. + + + tycho-its-project.p2Repository.downloadVerifyNoDigestAlgo.target + eclipse-target-definition + diff --git a/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.target/test.target b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.target/test.target new file mode 100644 index 0000000000..a2cdca14cd --- /dev/null +++ b/tycho-its/projects/p2Repository.downloadVerifyNoDigestAlgo/test.target/test.target @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + com.github.com-github-javabdd + com.github.javabdd + 6.0.0 + jar + + + org.apache.commons + commons-lang3 + 3.1 + jar + + + org.apache.commons + commons-text + 1.10.0 + jar + + + + + \ No newline at end of file diff --git a/tycho-its/src/test/java/org/eclipse/tycho/test/p2Repository/DownloadVerifyNoDigestAlgoTest.java b/tycho-its/src/test/java/org/eclipse/tycho/test/p2Repository/DownloadVerifyNoDigestAlgoTest.java new file mode 100644 index 0000000000..db6cd4a84a --- /dev/null +++ b/tycho-its/src/test/java/org/eclipse/tycho/test/p2Repository/DownloadVerifyNoDigestAlgoTest.java @@ -0,0 +1,25 @@ +/******************************************************************************* + * Copyright (c) 2023 Contributors to the Eclipse Foundation + * This program and the accompanying materials + * are made available under the terms of the Eclipse Public License 2.0 + * which accompanies this distribution, and is available at + * https://www.eclipse.org/legal/epl-2.0/ + * + * SPDX-License-Identifier: EPL-2.0 + *******************************************************************************/ + +package org.eclipse.tycho.test.p2Repository; + +import org.apache.maven.it.Verifier; +import org.eclipse.tycho.test.AbstractTychoIntegrationTest; +import org.junit.Test; + +public class DownloadVerifyNoDigestAlgoTest extends AbstractTychoIntegrationTest { + @Test + public void test() throws Exception { + Verifier verifier = getVerifier("p2Repository.downloadVerifyNoDigestAlgo", false); + verifier.executeGoal("verify"); + verifier.verifyErrorFreeLog(); + verifyTextNotInLog(verifier, "No digest algorithm is available to verify download"); + } +}