summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Rapicault (Ericsson)2013-04-17 10:08:49 (EDT)
committerPascal Rapicault2013-04-17 10:08:49 (EDT)
commited737150b21f670630c8c064af3b4a7bef84dfc5 (patch)
tree5649ee0cc2ad2eb64c24428daf828faf74c66daa
parent3f717b86dcb207491ba99f92c99b56e5d3ac4e2d (diff)
downloadrt.equinox.p2-ed737150b21f670630c8c064af3b4a7bef84dfc5.zip
rt.equinox.p2-ed737150b21f670630c8c064af3b4a7bef84dfc5.tar.gz
rt.equinox.p2-ed737150b21f670630c8c064af3b4a7bef84dfc5.tar.bz2
Re-enable tests for 1.6
-rw-r--r--bundles/org.eclipse.equinox.p2.tests/META-INF/MANIFEST.MF3
-rw-r--r--bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/AllTests.java1
-rw-r--r--bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/InitialSharedInstall.java12
3 files changed, 15 insertions, 1 deletions
diff --git a/bundles/org.eclipse.equinox.p2.tests/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.p2.tests/META-INF/MANIFEST.MF
index 7d199e7..7ce47e8 100644
--- a/bundles/org.eclipse.equinox.p2.tests/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.equinox.p2.tests/META-INF/MANIFEST.MF
@@ -55,7 +55,8 @@ Require-Bundle: org.eclipse.equinox.frameworkadmin,
org.eclipse.equinox.p2.operations;bundle-version="2.1.0",
org.eclipse.equinox.p2.ui.sdk.scheduler
Eclipse-RegisterBuddy: org.eclipse.equinox.p2.artifact.repository
-Bundle-RequiredExecutionEnvironment: JavaSE-1.7
+Bundle-RequiredExecutionEnvironment: JavaSE-1.7,
+ JavaSE-1.6
Eclipse-BundleShape: dir
Bundle-ActivationPolicy: lazy
Import-Package: javax.xml.parsers,
diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/AllTests.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/AllTests.java
index 81a75e4..eb6db23 100644
--- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/AllTests.java
+++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/AllTests.java
@@ -25,6 +25,7 @@ public class AllTests extends TestCase {
suite.addTest(BaseChangeWithoutUserChange.suite());
suite.addTest(Cancellation.suite());
suite.addTest(DoubleBaseChange.suite());
+ suite.addTest(InitialSharedInstall.suite());
suite.addTest(InstallInUserSpace.suite());
suite.addTest(MultipleChanges.suite());
suite.addTestSuite(NeedsMigration.class);
diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/InitialSharedInstall.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/InitialSharedInstall.java
index 527eeff..2227a70 100644
--- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/InitialSharedInstall.java
+++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/InitialSharedInstall.java
@@ -25,6 +25,9 @@ public class InitialSharedInstall extends AbstractSharedInstallTest {
public static Test suite() {
TestSuite suite = new ReconcilerTestSuite();
+ if (isRunningJava16orPrevious())
+ return suite;
+
suite.setName(InitialSharedInstall.class.getName());
suite.addTest(new InitialSharedInstall("setupRun"));
@@ -35,6 +38,15 @@ public class InitialSharedInstall extends AbstractSharedInstallTest {
return suite;
}
+ public static boolean isRunningJava16orPrevious() {
+ try {
+ Class.forName("java.nio.file.attribute.AclEntry");
+ } catch (ClassNotFoundException e) {
+ return true;
+ }
+ return false;
+ }
+
public InitialSharedInstall(String name) {
super(name);
}