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

Various maintenance tasks #582

Merged
merged 4 commits into from
Dec 17, 2024
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
2 changes: 1 addition & 1 deletion .mvn/extensions.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@
<extension>
<groupId>org.eclipse.tycho</groupId>
<artifactId>tycho-build</artifactId>
<version>4.0.7</version>
<version>4.0.10</version>
</extension>
</extensions>
2 changes: 1 addition & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ pipeline {
}
tools {
maven 'apache-maven-latest'
jdk 'temurin-jdk17-latest'
jdk 'temurin-jdk21-latest'
}
stages {
stage('Build') {
Expand Down
2 changes: 1 addition & 1 deletion bundles/org.eclipse.equinox.p2.tests/META-INF/MANIFEST.MF
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ Export-Package: org.eclipse.equinox.p2.tests;version="2.0.0",
Require-Bundle: org.eclipse.equinox.frameworkadmin,
org.eclipse.equinox.common,
org.eclipse.core.tests.harness;bundle-version="3.4.0",
org.eclipse.core.runtime;bundle-version="3.29.0",
org.eclipse.core.runtime;bundle-version="3.30.0",
org.eclipse.equinox.p2.publisher;bundle-version="1.0.0",
org.eclipse.equinox.frameworkadmin.test;bundle-version="1.0.0",
org.junit;bundle-version="4.8.0",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,26 +98,26 @@ public void testBasicStartup() throws IOException {
try {
File userBundlesInfo = new File(userBase, "configuration/org.eclipse.equinox.simpleconfigurator/bundles.info");
File userConfigIni = new File(userBase, "configuration/config.ini");
assertFalse("0.1", userBundlesInfo.exists());
assertFalse("0.2", userConfigIni.exists());
reconcileReadOnly("0.21", extensions);
assertFalse("0.3", userBundlesInfo.exists());
assertTrue("0.4", userConfigIni.exists());
assertFalse(userBundlesInfo.exists());
assertFalse(userConfigIni.exists());
reconcileReadOnly("", extensions);
assertFalse(userBundlesInfo.exists());
assertTrue(userConfigIni.exists());

Properties props = new Properties();
try (InputStream is = new BufferedInputStream(new FileInputStream(userConfigIni))) {
props.load(is);
}
assertTrue("0.5", props.containsKey("osgi.sharedConfiguration.area"));
assertTrue("0.6", props.size() == 1);
assertTrue(props.containsKey("osgi.sharedConfiguration.area"));
assertEquals(1, props.size());
} finally {
cleanupReadOnlyInstall();
}
}

@Override
public void testReadOnlyDropinsStartup() throws IOException {
if (Platform.getOS().equals(Platform.OS_MACOSX))
if (Platform.OS.isMac())
return;

assertInitialized();
Expand All @@ -128,21 +128,21 @@ public void testReadOnlyDropinsStartup() throws IOException {
try {
File userBundlesInfo = new File(userBase, "configuration/org.eclipse.equinox.simpleconfigurator/bundles.info");
File userConfigIni = new File(userBase, "configuration/config.ini");
assertFalse("0.1", userBundlesInfo.exists());
assertFalse("0.2", userConfigIni.exists());
assertFalse(userBundlesInfo.exists());
assertFalse(userConfigIni.exists());

reconcileReadOnly("0.21", extensions);

assertTrue("0.3", userBundlesInfo.exists());
assertTrue("0.4", userConfigIni.exists());
assertTrue(userBundlesInfo.exists());
assertTrue(userConfigIni.exists());

assertTrue(isInBundlesInfo(userBundlesInfo, "myBundle", null));
assertTrue(isInBundlesInfo(userBundlesInfo, "zzz", null));

// remove the bundle from the dropins and reconcile
setReadOnly(readOnlyBase, false);
AbstractSharedInstallTest.removeReallyReadOnly(readOnlyBase);
assertTrue("0.7", readOnlyBase.canWrite());
assertTrue(readOnlyBase.canWrite());
remove("1.0", "dropins", "myBundle_1.0.0.jar");
setReadOnly(readOnlyBase, true);
AbstractSharedInstallTest.reallyReadOnly(readOnlyBase);
Expand All @@ -164,7 +164,7 @@ public void testReadOnlyDropinsStartup() throws IOException {
// new, up-to-date bundles.info
setReadOnly(readOnlyBase, false);
AbstractSharedInstallTest.removeReallyReadOnly(readOnlyBase);
assertTrue("0.7", readOnlyBase.canWrite());
assertTrue(readOnlyBase.canWrite());
add("0.211", "dropins", jar);
setReadOnly(readOnlyBase, true);
AbstractSharedInstallTest.reallyReadOnly(readOnlyBase);
Expand All @@ -183,7 +183,7 @@ public void testReadOnlyDropinsStartup() throws IOException {

@Override
public void testUserDropinsStartup() throws IOException {
if (Platform.getOS().equals(Platform.OS_MACOSX))
if (Platform.OS.isMac())
return;

assertInitialized();
Expand All @@ -198,13 +198,13 @@ public void testUserDropinsStartup() throws IOException {

File userBundlesInfo = new File(userBase, "configuration/org.eclipse.equinox.simpleconfigurator/bundles.info");
File userConfigIni = new File(userBase, "configuration/config.ini");
assertFalse("0.1", userBundlesInfo.exists());
assertFalse("0.2", userConfigIni.exists());
assertFalse(userBundlesInfo.exists());
assertFalse(userConfigIni.exists());

reconcileReadOnly("0.21", extensions);

assertTrue("0.3", userBundlesInfo.exists());
assertTrue("0.4", userConfigIni.exists());
assertTrue(userBundlesInfo.exists());
assertTrue(userConfigIni.exists());

assertTrue(isInBundlesInfo(userBundlesInfo, "myBundle", null));
assertTrue(isInBundlesInfo(userBundlesInfo, "zzz", null));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ Bundle-SymbolicName: org.eclipse.equinox.p2.examples.rcp.discovery;singleton:=tr
Bundle-Version: 2.3.100.qualifier
Bundle-Activator: org.eclipse.equinox.p2.examples.rcp.cloud.Activator
Bundle-Localization: plugin
Bundle-Vendor: Eclipse.org - Equinox
Require-Bundle: org.eclipse.ui;bundle-version="3.6.0",
org.eclipse.core.runtime,
org.eclipse.equinox.p2.operations;bundle-version="2.0.0",
Expand Down
Loading