Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge AllPDEMinimalTests into AllPDETests and merge minimal tests #745

Merged
merged 2 commits into from
Sep 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion ui/org.eclipse.pde.ui.tests/META-INF/MANIFEST.MF
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,18 @@ Require-Bundle: org.eclipse.pde.ui,
org.eclipse.pde.genericeditor.extension,
org.eclipse.equinox.simpleconfigurator.manipulator;bundle-version="2.1.300",
org.eclipse.platform,
org.eclipse.ui.ide.application
org.eclipse.ui.ide.application,
org.eclipse.pde.api.tools,
org.eclipse.jsch.core,
org.eclipse.jdt.doc.user,
org.junit.source;resolution:=optional,
org.eclipse.pde.ui.source;resolution:=optional,
org.apache.ant.source;resolution:=optional,
org.eclipse.jdt.debug.source;resolution:=optional,
org.eclipse.jsch.core.source;resolution:=optional,
org.eclipse.core.filebuffers.source;resolution:=optional,
org.eclipse.jdt.doc.user;resolution:=optional,
org.eclipse.pde.build.source;resolution:=optional
Import-Package: javax.annotation;version="[1.3.0,2.0.0)",
javax.inject;version="[1.0.0,2.0.0)",
org.assertj.core.api;version="3.14.0",
Expand Down
2 changes: 1 addition & 1 deletion ui/org.eclipse.pde.ui.tests/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
<code.ignoredWarnings>-warn:-discouraged</code.ignoredWarnings>
<defaultSigning-excludeInnerJars>true</defaultSigning-excludeInnerJars>
<testSuite>${project.artifactId}</testSuite>
<testClass>org.eclipse.pde.ui.tests.AllPDEMinimalTests</testClass>
<testClass>org.eclipse.pde.ui.tests.AllPDETests</testClass>
</properties>

<build>
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2005,2021 IBM Corporation and others.
* Copyright (c) 2005, 2023 IBM Corporation and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
Expand All @@ -15,6 +15,8 @@

import org.eclipse.pde.core.tests.internal.AllPDECoreTests;
import org.eclipse.pde.core.tests.internal.classpath.ClasspathResolutionTest;
import org.eclipse.pde.core.tests.internal.core.builders.BundleErrorReporterTest;
import org.eclipse.pde.core.tests.internal.util.PDESchemaHelperTest;
import org.eclipse.pde.ui.tests.build.properties.AllValidatorTests;
import org.eclipse.pde.ui.tests.classpathcontributor.ClasspathContributorTest;
import org.eclipse.pde.ui.tests.classpathresolver.ClasspathResolverTest;
Expand All @@ -38,27 +40,29 @@
import org.junit.runners.Suite.SuiteClasses;

@RunWith(Suite.class)
@SuiteClasses({
AllTargetTests.class,
AllNewProjectTests.class,
AllPreferenceTests.class,
AllImportTests.class,
AllBundleModelTests.class,
AllXMLModelTests.class,
AllValidatorTests.class,
AllNLSTests.class,
AllPDERuntimeTests.class,
ExportBundleTests.class,
AllLauncherTests.class,
AllLogViewTests.class,
ProjectCreationTests.class,
BundleRootTests.class,
PluginRegistryTests.class,
ClasspathResolverTest.class,
ClasspathContributorTest.class,
DynamicPluginProjectReferencesTest.class,
ClasspathResolutionTest.class,
AllPDECoreTests.class
@SuiteClasses({ //
AllTargetTests.class, //
AllNewProjectTests.class, //
AllPreferenceTests.class, //
AllImportTests.class, //
AllBundleModelTests.class, //
AllXMLModelTests.class, //
AllValidatorTests.class, //
AllNLSTests.class, //
AllPDERuntimeTests.class, //
ExportBundleTests.class, //
AllLauncherTests.class, //
AllLogViewTests.class, //
ProjectCreationTests.class, //
BundleRootTests.class, //
PluginRegistryTests.class, //
ClasspathResolverTest.class, //
PDESchemaHelperTest.class, //
ClasspathContributorTest.class, //
DynamicPluginProjectReferencesTest.class, //
ClasspathResolutionTest.class, //
BundleErrorReporterTest.class, //
AllPDECoreTests.class //
})
public class AllPDETests {

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2005, 2015 IBM Corporation and others.
* Copyright (c) 2005, 2023 IBM Corporation and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
Expand All @@ -14,6 +14,12 @@
package org.eclipse.pde.ui.tests;

import static org.junit.Assert.fail;
import static org.junit.Assume.assumeTrue;

import java.net.URISyntaxException;
import java.nio.file.Files;
import java.nio.file.Path;
import java.util.List;

import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.IWorkspaceRoot;
Expand All @@ -22,6 +28,7 @@
import org.eclipse.core.runtime.ICoreRunnable;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.NullProgressMonitor;
import org.eclipse.core.runtime.Platform;
import org.eclipse.core.runtime.jobs.Job;
import org.eclipse.jface.dialogs.ErrorDialog;
import org.eclipse.jface.dialogs.MessageDialog;
Expand Down Expand Up @@ -131,4 +138,15 @@ private static void closeIntro(final IWorkbench wb) {
}
}
}

public static void assumeRunningInStandaloneEclipseSDK() {
try {
Path location = Path.of(Platform.getInstallLocation().getURL().toURI());
for (String directory : List.of("plugins", "features")) {
assumeTrue("Not running in a standalone Eclipse SDK", Files.isDirectory(location.resolve(directory)));
}
} catch (URISyntaxException e) {
throw new IllegalStateException(e);
}
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2008, 2017 IBM Corporation and others.
* Copyright (c) 2008, 2023 IBM Corporation and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
Expand Down Expand Up @@ -41,13 +41,19 @@
import org.eclipse.pde.ui.tests.runtime.TestUtils;
import org.eclipse.pde.ui.tests.util.ProjectUtils;
import org.junit.Before;
import org.junit.BeforeClass;
import org.junit.Test;

/**
* Tests exporting bundles.
*/
public class ExportBundleTests extends PDETestCase {

@BeforeClass
public static void requireStandaloneEclipseSDKEnvironment() {
PDETestCase.assumeRunningInStandaloneEclipseSDK();
}

private static final IPath EXPORT_PATH = PDETestsPlugin.getDefault().getStateLocation().append(".export");

@Override
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2005, 2017 IBM Corporation and others.
* Copyright (c) 2005, 2023 IBM Corporation and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
Expand All @@ -17,9 +17,9 @@
import org.junit.runners.Suite;
import org.junit.runners.Suite.SuiteClasses;


@RunWith(Suite.class)
@SuiteClasses({ ImportWithLinksTestCase.class, ImportAsBinaryTestCase.class, ImportAsSourceTestCase.class,
@SuiteClasses({ //
BaseImportTestCase.class, //

// Temporarily disabled until git migration is complete and we have access to a
// stable cvs repo (bug 355873)
Expand Down
Loading
Loading