Skip to content

Commit

Permalink
chore: update (nearly) all the dependencies (#709)
Browse files Browse the repository at this point in the history
* chore: update github-api 1.306 >>> 1.318
* chore: update com.vdurmont.semver4j 3.1.0 >>> org.semver4j.semver4j 5.2.2
* chore: update fx-gson 4.0.1 >>> 5.0.0
* chore: update junit 5.9.0 >>> 5.9.2
* chore: update mockito 4.8.0 >>> 5.2.0
  • Loading branch information
skaldarnar authored Nov 25, 2023
1 parent 1d0c05b commit da5d3b2
Show file tree
Hide file tree
Showing 13 changed files with 39 additions and 39 deletions.
16 changes: 8 additions & 8 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -102,11 +102,11 @@ dependencies {
implementation group: "com.google.guava", name: "guava", version: "31.1-jre"
implementation group: 'com.github.everit-org.json-schema', name: 'org.everit.json.schema', version: '1.14.1'

implementation group: 'org.kohsuke', name: 'github-api', version: '1.306'
implementation group: 'com.vdurmont', name: 'semver4j', version: '3.1.0'
implementation group: 'org.kohsuke', name: 'github-api', version: '1.318'
implementation group: 'org.semver4j', name: 'semver4j', version: '5.2.2'
implementation group: 'com.vladsch.flexmark', name: 'flexmark-all', version: '0.64.0'

implementation('org.hildan.fxgson:fx-gson:4.0.1') {
implementation('org.hildan.fxgson:fx-gson:5.0.0') {
because "de-/serialization of launcher properties to JSON"
}

Expand All @@ -117,16 +117,16 @@ dependencies {
// These dependencies are only needed for running tests

testImplementation 'org.hamcrest:hamcrest:2.2'
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.9.0'
testImplementation 'org.junit.jupiter:junit-jupiter-params:5.9.0'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.9.0'
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.9.2'
testImplementation 'org.junit.jupiter:junit-jupiter-params:5.9.2'
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine:5.9.2'

testImplementation('org.mockito:mockito-inline:4.8.0') {
testImplementation('org.mockito:mockito-inline:5.2.0') {
because "-inline build enables mocking final classes"
// https://javadoc.io/doc/org.mockito/mockito-core/latest/org/mockito/Mockito.html#0.2
// > Be aware that this artifact may be abolished when the inline mock making feature is integrated into the default mock maker.
}
testImplementation 'org.mockito:mockito-junit-jupiter:4.8.0'
testImplementation 'org.mockito:mockito-junit-jupiter:5.2.0'

testImplementation('org.spf4j:spf4j-slf4j-test:8.9.5') {
because "testable logging"
Expand Down
18 changes: 9 additions & 9 deletions gradle.lockfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@
ch.qos.logback:logback-classic:1.3.0-alpha16=compileClasspath
ch.qos.logback:logback-core:1.3.0-alpha16=compileClasspath
com.damnhandy:handy-uri-templates:2.1.8=compileClasspath
com.fasterxml.jackson.core:jackson-annotations:2.13.2=compileClasspath
com.fasterxml.jackson.core:jackson-core:2.13.2=compileClasspath
com.fasterxml.jackson.core:jackson-databind:2.13.2.2=compileClasspath
com.fasterxml.jackson:jackson-bom:2.13.2=compileClasspath
com.fasterxml.jackson.core:jackson-annotations:2.15.3=compileClasspath
com.fasterxml.jackson.core:jackson-core:2.15.3=compileClasspath
com.fasterxml.jackson.core:jackson-databind:2.15.3=compileClasspath
com.fasterxml.jackson:jackson-bom:2.15.3=compileClasspath
com.github.everit-org.json-schema:org.everit.json.schema:1.14.1=compileClasspath
com.google.code.findbugs:jsr305:3.0.2=compileClasspath
com.google.code.gson:gson:2.8.6=compileClasspath
com.google.code.gson:gson:2.10=compileClasspath
com.google.errorprone:error_prone_annotations:2.11.0=compileClasspath
com.google.guava:failureaccess:1.0.1=compileClasspath
com.google.guava:guava:31.1-jre=compileClasspath
Expand All @@ -25,7 +25,6 @@ com.openhtmltopdf:openhtmltopdf-rtl-support:1.0.10=compileClasspath
com.squareup.okhttp3:okhttp:4.10.0=compileClasspath
com.squareup.okio:okio-jvm:3.0.0=compileClasspath
com.squareup.okio:okio:3.0.0=compileClasspath
com.vdurmont:semver4j:3.1.0=compileClasspath
com.vladsch.flexmark:flexmark-all:0.64.0=compileClasspath
com.vladsch.flexmark:flexmark-ext-abbreviation:0.64.0=compileClasspath
com.vladsch.flexmark:flexmark-ext-admonition:0.64.0=compileClasspath
Expand Down Expand Up @@ -87,21 +86,22 @@ org.apache.pdfbox:fontbox:2.0.24=compileClasspath
org.apache.pdfbox:pdfbox:2.0.24=compileClasspath
org.apache.pdfbox:xmpbox:2.0.24=compileClasspath
org.checkerframework:checker-qual:3.12.0=compileClasspath
org.hildan.fxgson:fx-gson:4.0.1=compileClasspath
org.hildan.fxgson:fx-gson:5.0.0=compileClasspath
org.jetbrains.kotlin:kotlin-stdlib-common:1.6.20=compileClasspath
org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.6.20=compileClasspath
org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.6.20=compileClasspath
org.jetbrains.kotlin:kotlin-stdlib:1.6.20=compileClasspath
org.jetbrains:annotations:15.0=compileClasspath
org.jetbrains:annotations:23.0.0=compileClasspath
org.json:json:20220320=compileClasspath
org.jsoup:jsoup:1.14.3=compileClasspath
org.kohsuke:github-api:1.306=compileClasspath
org.kohsuke:github-api:1.318=compileClasspath
org.nibor.autolink:autolink:0.6.0=compileClasspath
org.openjfx:javafx-base:17.0.2=compileClasspath
org.openjfx:javafx-controls:17.0.2=compileClasspath
org.openjfx:javafx-fxml:17.0.2=compileClasspath
org.openjfx:javafx-graphics:17.0.2=compileClasspath
org.openjfx:javafx-media:17.0.2=compileClasspath
org.openjfx:javafx-web:17.0.2=compileClasspath
org.semver4j:semver4j:5.2.2=compileClasspath
org.slf4j:slf4j-api:2.0.0-alpha7=compileClasspath
empty=
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

package org.terasology.launcher.game;

import com.vdurmont.semver4j.Semver;
import org.semver4j.Semver;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.slf4j.event.Level;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

package org.terasology.launcher.game;

import com.vdurmont.semver4j.Semver;
import org.semver4j.Semver;

public class GameVersionNotSupportedException extends RuntimeException {
private final Semver engineVersion;
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/org/terasology/launcher/game/Installation.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
package org.terasology.launcher.game;

import com.google.common.base.MoreObjects;
import com.vdurmont.semver4j.Semver;
import org.semver4j.Semver;

import java.io.FileNotFoundException;
import java.io.IOException;
Expand Down Expand Up @@ -117,7 +117,7 @@ static Path findJar(Path searchPath, BiPredicate<Path, BasicFileAttributes> pred
static Semver getEngineVersion(Path versionDirectory) throws IOException {
Path engineJar = findJar(versionDirectory, Installation::matchEngineJar, "engine");
Properties versionInfo = getVersionPropertiesFromJar(engineJar);
return new Semver(versionInfo.getProperty("engineVersion"), Semver.SemverType.IVY);
return new Semver(versionInfo.getProperty("engineVersion"));
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

package org.terasology.launcher.game;

import com.vdurmont.semver4j.Semver;
import org.semver4j.Semver;

/**
* Terasology versions which introduce specific features.
Expand Down Expand Up @@ -31,7 +31,7 @@ public enum VersionHistory {
public final Semver engineVersion;

VersionHistory(String s) {
engineVersion = new Semver(s, Semver.SemverType.IVY);
engineVersion = new Semver(s);
}

boolean isProvidedBy(Semver version) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
package org.terasology.launcher.model;

import com.google.common.io.Resources;
import com.vdurmont.semver4j.Semver;
import com.vdurmont.semver4j.SemverException;
import org.semver4j.Semver;
import org.semver4j.SemverException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

Expand Down Expand Up @@ -44,7 +44,7 @@ public static synchronized LauncherVersion getInstance() {
}

public String getDisplayName() {
return Optional.ofNullable(semver).map(Semver::getValue).orElse("n/a");
return Optional.ofNullable(semver).map(Semver::getVersion).orElse("n/a");
}

public Semver getSemver() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@

package org.terasology.launcher.repositories;

import com.vdurmont.semver4j.Semver;
import com.vdurmont.semver4j.SemverException;
import org.semver4j.Semver;
import org.semver4j.SemverException;
import okhttp3.OkHttpClient;
import org.kohsuke.github.GHAsset;
import org.kohsuke.github.GHRelease;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

package org.terasology.launcher.updater;

import com.vdurmont.semver4j.Semver;
import org.semver4j.Semver;
import javafx.application.Platform;
import javafx.scene.Parent;
import javafx.scene.control.Alert;
Expand Down Expand Up @@ -81,12 +81,12 @@ private FutureTask<Boolean> getUpdateDialog(Stage parentStage, GHRelease release
final String infoText = " " +
I18N.getLabel("message_update_current") +
" " +
currentVersion.getValue() +
currentVersion.getVersion() +
" \n" +
" " +
I18N.getLabel("message_update_latest") +
" " +
versionOf(release).getValue() +
versionOf(release).getVersion() +
" ";

return new FutureTask<>(() -> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

package org.terasology.launcher.game;

import com.vdurmont.semver4j.Semver;
import org.semver4j.Semver;

import java.nio.file.Path;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// SPDX-License-Identifier: Apache-2.0
package org.terasology.launcher.game;

import com.vdurmont.semver4j.Semver;
import org.semver4j.Semver;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.params.ParameterizedTest;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

package org.terasology.launcher.game;

import com.vdurmont.semver4j.Semver;
import org.semver4j.Semver;
import org.junit.jupiter.params.ParameterizedTest;
import org.junit.jupiter.params.provider.ValueSource;

Expand All @@ -16,13 +16,13 @@ class VersionHistoryTest {
@ParameterizedTest
@ValueSource(strings = {"5.2.0-SNAPSHOT", "5.2.0", "5.2.1", "6.0.0"})
void hasPicocli(String version) {
assertTrue(VersionHistory.PICOCLI.isProvidedBy(new Semver(version, Semver.SemverType.IVY)));
assertTrue(VersionHistory.PICOCLI.isProvidedBy(new Semver(version)));
}

@ParameterizedTest
@ValueSource(strings = {"5.1.0", "5.1.0-SNAPSHOT", "5.1.1"})
void lacksPicocli(String version) {
assertFalse(VersionHistory.PICOCLI.isProvidedBy(new Semver(version, Semver.SemverType.IVY)));
assertFalse(VersionHistory.PICOCLI.isProvidedBy(new Semver(version)));
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
package org.terasology.launcher.repositories;

import com.google.gson.Gson;
import com.vdurmont.semver4j.Semver;
import org.semver4j.Semver;
import org.junit.jupiter.api.BeforeAll;
import org.junit.jupiter.api.DisplayName;
import org.junit.jupiter.api.Test;
Expand Down Expand Up @@ -76,12 +76,12 @@ void skipBuildsWithoutVersionInfo() {
@DisplayName("process valid response correctly")
void processValidResponseCorrectly() {
String displayVersion = "alpha 42 (preview)";
Semver engineVersion = new Semver("5.0.1-SNAPSHOT", Semver.SemverType.IVY);
Semver engineVersion = new Semver("5.0.1-SNAPSHOT");

Properties versionInfo = new Properties();
versionInfo.setProperty("buildNumber", validResult.builds[0].number);
versionInfo.setProperty("displayVersion", displayVersion);
versionInfo.setProperty("engineVersion", engineVersion.getValue());
versionInfo.setProperty("engineVersion", engineVersion.getVersion());

final JenkinsClient stubClient = new StubJenkinsClient(url -> validResult, url -> versionInfo);

Expand Down

0 comments on commit da5d3b2

Please sign in to comment.