From 27bd0325d4cce43d0acea15ed144210910654342 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=90=D0=BB=D0=B5=D0=BA=D1=81=D0=B0=D0=BD=D0=B4=D1=8A?= =?UTF-8?q?=D1=80=20=D0=9A=D1=83=D1=80=D1=82=D0=B0=D0=BA=D0=BE=D0=B2?= Date: Wed, 23 Aug 2023 16:55:24 +0300 Subject: [PATCH] Remove packedSiblingsWithUUID test It was useless since pack200 support was removed but didn't fail as packed artifacts were not ignored entirely (at parsing time) --- .../tests/artifact/repository/AllTests.java | 2 +- .../artifact/repository/LocationTest.java | 62 ------------------- .../5e/00c3579a3138001f1093800c21638bce | 1 - .../packedSiblingsWithUUID/artifacts.xml | 26 -------- 4 files changed, 1 insertion(+), 90 deletions(-) delete mode 100644 bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/LocationTest.java delete mode 100644 bundles/org.eclipse.equinox.p2.tests/testData/artifactRepo/packedSiblingsWithUUID/.blobstore/5e/00c3579a3138001f1093800c21638bce delete mode 100644 bundles/org.eclipse.equinox.p2.tests/testData/artifactRepo/packedSiblingsWithUUID/artifacts.xml diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/AllTests.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/AllTests.java index 0abfcc7088..4556213f46 100644 --- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/AllTests.java +++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/AllTests.java @@ -25,7 +25,7 @@ ArtifactRepositoryMissingSizeData.class, ArtifactRepositoryWithReferenceDescriptors.class, BatchExecuteArtifactRepositoryTest.class, Bug252308.class, Bug265577.class, Bug351944.class, CompositeArtifactRepositoryTest.class, CorruptedJar.class, FoldersRepositoryTest.class, - JarURLArtifactRepositoryTest.class, LocationTest.class, MD5Tests.class, MirrorSelectorTest.class, + JarURLArtifactRepositoryTest.class, MD5Tests.class, MirrorSelectorTest.class, MirrorRequestTest.class, SimpleArtifactRepositoryTest.class, TransferTest.class, PGPVerifierTest.class }) public class AllTests { diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/LocationTest.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/LocationTest.java deleted file mode 100644 index 4de0337e3c..0000000000 --- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/LocationTest.java +++ /dev/null @@ -1,62 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2011, 2017 IBM Corporation and others. - * - * 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 - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.equinox.p2.tests.artifact.repository; - -import java.io.File; -import org.eclipse.core.runtime.IStatus; -import org.eclipse.core.runtime.NullProgressMonitor; -import org.eclipse.equinox.internal.p2.artifact.repository.MirrorRequest; -import org.eclipse.equinox.internal.p2.artifact.repository.simple.SimpleArtifactRepository; -import org.eclipse.equinox.internal.p2.metadata.ArtifactKey; -import org.eclipse.equinox.p2.metadata.IArtifactKey; -import org.eclipse.equinox.p2.metadata.Version; -import org.eclipse.equinox.p2.repository.artifact.IArtifactRepository; -import org.eclipse.equinox.p2.repository.artifact.IArtifactRepositoryManager; -import org.eclipse.equinox.p2.tests.AbstractProvisioningTest; - -public class LocationTest extends AbstractProvisioningTest { - private static final String testDataLocation = "testData/artifactRepo/packedSiblingsWithUUID"; - private File targetLocation; - private IArtifactRepository targetRepository, sourceRepository; - - @Override - public void setUp() throws Exception { - super.setUp(); - targetLocation = File.createTempFile("target", ".repo"); - targetLocation.delete(); - targetLocation.mkdirs(); - targetRepository = new SimpleArtifactRepository(getAgent(), "TargetRepo", targetLocation.toURI(), null); - - IArtifactRepositoryManager mgr = getArtifactRepositoryManager(); - sourceRepository = mgr.loadRepository((getTestData("EmptyJar repo", testDataLocation).toURI()), null); - - } - - @Override - protected void tearDown() throws Exception { - getArtifactRepositoryManager().removeRepository(targetLocation.toURI()); - getArtifactRepositoryManager().removeRepository(sourceRepository.getLocation()); - AbstractProvisioningTest.delete(targetLocation); - super.tearDown(); - } - - public void testLocation() throws Exception { - IArtifactKey key = new ArtifactKey("osgi.bundle", "org.springframework.ide.eclipse", Version.parseVersion("2.3.2.201003220227-RELEASE")); - assertTrue(sourceRepository.contains(key)); - MirrorRequest req = new MirrorRequest(key, targetRepository, null, null, getTransport()); - req.perform(sourceRepository, new NullProgressMonitor()); - IStatus status = req.getResult(); - assertTrue(status.getMessage(), status.isOK()); - } -} diff --git a/bundles/org.eclipse.equinox.p2.tests/testData/artifactRepo/packedSiblingsWithUUID/.blobstore/5e/00c3579a3138001f1093800c21638bce b/bundles/org.eclipse.equinox.p2.tests/testData/artifactRepo/packedSiblingsWithUUID/.blobstore/5e/00c3579a3138001f1093800c21638bce deleted file mode 100644 index c57eff55eb..0000000000 --- a/bundles/org.eclipse.equinox.p2.tests/testData/artifactRepo/packedSiblingsWithUUID/.blobstore/5e/00c3579a3138001f1093800c21638bce +++ /dev/null @@ -1 +0,0 @@ -Hello World! \ No newline at end of file diff --git a/bundles/org.eclipse.equinox.p2.tests/testData/artifactRepo/packedSiblingsWithUUID/artifacts.xml b/bundles/org.eclipse.equinox.p2.tests/testData/artifactRepo/packedSiblingsWithUUID/artifacts.xml deleted file mode 100644 index 444db993c3..0000000000 --- a/bundles/org.eclipse.equinox.p2.tests/testData/artifactRepo/packedSiblingsWithUUID/artifacts.xml +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - -