blob: b474a54d13a93aba3105a57db94d0fb2e0b659e8 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
|
/*******************************************************************************
* Copyright (c) 2013 Ericsson AB and others. All rights reserved. This
* program and the accompanying materials are made available under the terms of
* the Eclipse Public License v1.0 which accompanies this distribution, and is
* available at http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Ericsson AB - initial API and implementation
******************************************************************************/
package org.eclipse.equinox.p2.tests.sharedinstall;
import junit.framework.Test;
import junit.framework.TestSuite;
import org.eclipse.equinox.p2.engine.IProfile;
import org.eclipse.equinox.p2.tests.reconciler.dropins.ReconcilerTestSuite;
public class InstallInUserSpace extends AbstractSharedInstallTest {
public static Test suite() {
TestSuite suite = new ReconcilerTestSuite();
suite.setName(InstallInUserSpace.class.getName());
suite.addTest(new InstallInUserSpace("testInstallInUserSpace"));
return suite;
}
public InstallInUserSpace(String name) {
super(name);
}
public void testInstallInUserSpace() {
assertInitialized();
setupReadOnlyInstall();
System.out.println(readOnlyBase);
System.out.println(userBase);
installFeature1AndVerifierInUser();
assertTrue(isInUserBundlesInfo("p2TestBundle1"));
assertTrue(isInUserBundlesInfo("org.eclipse.swt")); //this verifies that we have the bundles from the base installed in the user bundles.info
assertTrue(getUserBundleInfoTimestamp().exists());
assertTrue(getConfigIniTimestamp().exists());
assertProfileStatePropertiesHasKey(getUserProfileFolder(), IProfile.STATE_PROP_SHARED_INSTALL);
assertProfileStatePropertiesHasValue(getUserProfileFolder(), IProfile.STATE_SHARED_INSTALL_VALUE_INITIAL);
assertProfileStatePropertiesHasKey(getUserProfileFolder(), "_simpleProfileRegistry_internal_" + getMostRecentProfileTimestampFromBase());
assertEquals(runningWithReconciler ? 3 : 2, getProfileTimestampsFromUser().length);
}
}
|