summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Rapicault2013-02-13 14:15:08 (EST)
committerPascal Rapicault2013-02-13 14:15:08 (EST)
commit211a40285eb250eaac12c85c0d7e498d1bbb96c1 (patch)
tree2679548f5f542922538a459d36542959878a79ef
parent7d5e191324952de080b7301c9c385906a6480e62 (diff)
downloadrt.equinox.p2-211a40285eb250eaac12c85c0d7e498d1bbb96c1.zip
rt.equinox.p2-211a40285eb250eaac12c85c0d7e498d1bbb96c1.tar.gz
rt.equinox.p2-211a40285eb250eaac12c85c0d7e498d1bbb96c1.tar.bz2
Use director application instead of GC when running shared install tests
-rw-r--r--bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/AbstractSharedInstallTest.java3
-rw-r--r--bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/InstallInUserSpace.java3
-rw-r--r--bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/TestInitialRun.java3
3 files changed, 5 insertions, 4 deletions
diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/AbstractSharedInstallTest.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/AbstractSharedInstallTest.java
index 5a5a5b7..e07ca2d 100644
--- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/AbstractSharedInstallTest.java
+++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/AbstractSharedInstallTest.java
@@ -19,6 +19,7 @@ public abstract class AbstractSharedInstallTest extends AbstractReconcilerTest {
protected static File readOnlyBase;
protected static File userBase;
protected static String profileId;
+ public boolean runningWithReconciler = true;
public File getUserBundleInfo() {
return new File(userBase, "configuration/org.eclipse.equinox.simpleconfigurator/bundles.info");
@@ -123,7 +124,7 @@ public abstract class AbstractSharedInstallTest extends AbstractReconcilerTest {
}
protected void startEclipseAsUser() {
- runEclipse("Running eclipse", output, new String[] {"-configuration", userBase.getAbsolutePath() + java.io.File.separatorChar + "configuration", "-application", "org.eclipse.equinox.p2.garbagecollector.application", "-profile", "_SELF_"});
+ runEclipse("Running eclipse", output, new String[] {"-configuration", userBase.getAbsolutePath() + java.io.File.separatorChar + "configuration", "-application", "org.eclipse.equinox.p2.director", "-listInstalledRoots"});
}
protected void executeVerifier(Properties verificationProperties) {
diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/InstallInUserSpace.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/InstallInUserSpace.java
index 37c442f..cb69fe3 100644
--- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/InstallInUserSpace.java
+++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/InstallInUserSpace.java
@@ -42,7 +42,6 @@ public class InstallInUserSpace extends AbstractSharedInstallTest {
assertProfileStatePropertiesHasKey(getUserProfileFolder(), IProfile.STATE_PROP_SHARED_INSTALL);
assertProfileStatePropertiesHasValue(getUserProfileFolder(), IProfile.STATE_SHARED_INSTALL_VALUE_INITIAL);
assertProfileStatePropertiesHasKey(getUserProfileFolder(), "_simpleProfileRegistry_internal_" + getMostRecentProfileTimestampFromBase());
- assertEquals(3, getProfileTimestampsFromUser().length);
+ assertEquals(runningWithReconciler ? 3 : 2, getProfileTimestampsFromUser().length);
}
-
}
diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/TestInitialRun.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/TestInitialRun.java
index cc381bb..b1525ec 100644
--- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/TestInitialRun.java
+++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/sharedinstall/TestInitialRun.java
@@ -33,7 +33,7 @@ public class TestInitialRun extends AbstractSharedInstallTest {
System.out.println(readOnlyBase);
System.out.println(userBase);
- //Here we are invoking the GC to force the profile to be loaded.
+ //Here we are invoking the director app with -listInstalledRoots to force the profile to be loaded.
startEclipseAsUser();
assertFalse(getUserBundleInfo().exists());
assertFalse(getUserBundleInfoTimestamp().exists());
@@ -41,4 +41,5 @@ public class TestInitialRun extends AbstractSharedInstallTest {
assertProfileStatePropertiesHasValue(getUserProfileFolder(), IProfile.STATE_SHARED_INSTALL_VALUE_INITIAL);
assertProfileStatePropertiesHasKey(getUserProfileFolder(), "_simpleProfileRegistry_internal_" + getMostRecentProfileTimestampFromBase());
}
+
}