diff --git a/.github/workflows/bld.yml b/.github/workflows/bld.yml index bf65051..f7e10f8 100644 --- a/.github/workflows/bld.yml +++ b/.github/workflows/bld.yml @@ -8,7 +8,7 @@ jobs: strategy: matrix: - java-version: [17, 21, 22] + java-version: [17, 21, 23] steps: - name: Checkout source repository diff --git a/config/pmd.xml b/config/pmd.xml index 3d3203c..2641880 100644 --- a/config/pmd.xml +++ b/config/pmd.xml @@ -7,9 +7,9 @@ - - + + diff --git a/examples/src/bld/java/com/example/PropertyFileExampleBuild.java b/examples/src/bld/java/com/example/PropertyFileExampleBuild.java index dc57ddc..db51540 100644 --- a/examples/src/bld/java/com/example/PropertyFileExampleBuild.java +++ b/examples/src/bld/java/com/example/PropertyFileExampleBuild.java @@ -42,8 +42,8 @@ public class PropertyFileExampleBuild extends Project { repositories = List.of(MAVEN_CENTRAL, RIFE2_RELEASES); scope(test) - .include(dependency("org.junit.jupiter", "junit-jupiter", version(5, 11, 0))) - .include(dependency("org.junit.platform", "junit-platform-console-standalone", version(1, 11, 0))); + .include(dependency("org.junit.jupiter", "junit-jupiter", version(5, 11, 3))) + .include(dependency("org.junit.platform", "junit-platform-console-standalone", version(1, 11, 3))); } public static void main(String[] args) { diff --git a/lib/bld/bld-wrapper.properties b/lib/bld/bld-wrapper.properties index c3b3e47..f148e62 100644 --- a/lib/bld/bld-wrapper.properties +++ b/lib/bld/bld-wrapper.properties @@ -1,6 +1,6 @@ bld.downloadExtensionJavadoc=false bld.downloadExtensionSources=true bld.downloadLocation= -bld.extension-pmd=com.uwyn.rife2:bld-pmd:1.1.5 +bld.extension-pmd=com.uwyn.rife2:bld-pmd:1.1.7 bld.repositories=MAVEN_CENTRAL,MAVEN_LOCAL,RIFE2_SNAPSHOTS,RIFE2_RELEASES bld.version=2.1.0 diff --git a/src/bld/java/rife/bld/extension/propertyfile/PropertyFileBuild.java b/src/bld/java/rife/bld/extension/propertyfile/PropertyFileBuild.java index cdeadb9..686b893 100644 --- a/src/bld/java/rife/bld/extension/propertyfile/PropertyFileBuild.java +++ b/src/bld/java/rife/bld/extension/propertyfile/PropertyFileBuild.java @@ -45,8 +45,8 @@ public class PropertyFileBuild extends Project { .include(dependency("com.uwyn.rife2", "bld", version(2, 1, 0))); scope(test) .include(dependency("org.jsoup", "jsoup", version(1, 18, 1))) - .include(dependency("org.junit.jupiter", "junit-jupiter", version(5, 11, 0))) - .include(dependency("org.junit.platform", "junit-platform-console-standalone", version(1, 11, 0))) + .include(dependency("org.junit.jupiter", "junit-jupiter", version(5, 11, 3))) + .include(dependency("org.junit.platform", "junit-platform-console-standalone", version(1, 11, 3))) .include(dependency("org.assertj:assertj-joda-time:2.2.0")); javadocOperation() @@ -58,6 +58,7 @@ public class PropertyFileBuild extends Project { publishOperation() .repository(version.isSnapshot() ? repository("rife2-snapshot") : repository("rife2")) + .repository(repository("github")) .info() .groupId("com.uwyn.rife2") .artifactId("bld-property-file") diff --git a/src/main/java/rife/bld/extension/propertyfile/PropertyFileOperation.java b/src/main/java/rife/bld/extension/propertyfile/PropertyFileOperation.java index ec5df99..d6ff5e4 100644 --- a/src/main/java/rife/bld/extension/propertyfile/PropertyFileOperation.java +++ b/src/main/java/rife/bld/extension/propertyfile/PropertyFileOperation.java @@ -35,7 +35,7 @@ import java.util.logging.Logger; * @since 1.0 */ public class PropertyFileOperation extends AbstractOperation { - private final static Logger LOGGER = Logger.getLogger(PropertyFileOperation.class.getName()); + private static final Logger LOGGER = Logger.getLogger(PropertyFileOperation.class.getName()); private final List> entries_ = new ArrayList<>(); private String comment_ = ""; private boolean failOnWarning_; diff --git a/src/main/java/rife/bld/extension/propertyfile/PropertyFileUtils.java b/src/main/java/rife/bld/extension/propertyfile/PropertyFileUtils.java index a172ded..e3c1cbb 100644 --- a/src/main/java/rife/bld/extension/propertyfile/PropertyFileUtils.java +++ b/src/main/java/rife/bld/extension/propertyfile/PropertyFileUtils.java @@ -39,7 +39,7 @@ import java.util.logging.Logger; * @since 1.0 */ public final class PropertyFileUtils { - private final static Logger LOGGER = Logger.getLogger(PropertyFileUtils.class.getName()); + private static final Logger LOGGER = Logger.getLogger(PropertyFileUtils.class.getName()); private PropertyFileUtils() { // no-op diff --git a/src/test/java/rife/bld/extension/propertyfile/PropertyFileOperationTest.java b/src/test/java/rife/bld/extension/propertyfile/PropertyFileOperationTest.java index 8fba1d0..db7adca 100644 --- a/src/test/java/rife/bld/extension/propertyfile/PropertyFileOperationTest.java +++ b/src/test/java/rife/bld/extension/propertyfile/PropertyFileOperationTest.java @@ -16,6 +16,7 @@ package rife.bld.extension.propertyfile; +import org.assertj.core.api.AutoCloseableSoftAssertions; import org.junit.jupiter.api.Test; import rife.bld.Project; import rife.bld.operations.exceptions.ExitStatusException; @@ -51,11 +52,13 @@ class PropertyFileOperationTest { var p = new Properties(); p.load(Files.newInputStream(tmpFile.toPath())); - assertThat(p.getProperty("version.major")).as("major").isEqualTo("1"); - assertThat(p.getProperty("version.minor")).as("minor").isEqualTo("0"); - assertThat(p.getProperty("version.patch")).as("patch").isEqualTo("0"); - assertThat(p.getProperty("build.date")).as("date") - .isEqualTo(LocalDate.now().format(DateTimeFormatter.ISO_LOCAL_DATE)); + try (var softly = new AutoCloseableSoftAssertions()) { + softly.assertThat(p.getProperty("version.major")).as("major").isEqualTo("1"); + softly.assertThat(p.getProperty("version.minor")).as("minor").isEqualTo("0"); + softly.assertThat(p.getProperty("version.patch")).as("patch").isEqualTo("0"); + softly.assertThat(p.getProperty("build.date")).as("date") + .isEqualTo(LocalDate.now().format(DateTimeFormatter.ISO_LOCAL_DATE)); + } new PropertyFileOperation() .fromProject(new Project())