Skip to content

Conversation

@haroon-sheikh
Copy link
Contributor

@haroon-sheikh haroon-sheikh commented Oct 31, 2025

This pull request updates the Java plugin for Gauge to version 0.14.0, drops support for Java 11, and modernizes the codebase by leveraging newer Java features and improving code quality. It also updates dependencies, notably upgrading JUnit to version 6, and makes various refactoring and cleanup changes for consistency and maintainability.

Build and Compatibility Updates:

  • Dropped support for Java 11 in CI workflows and build configuration, requiring Java 17 or newer for building and running the project. (.github/workflows/tests.yml, pom.xml)
  • Updated plugin and package versions to 0.14.0 in pom.xml and java.json.
  • Upgraded JUnit BOM dependency from 5.14.0 to 6.0.0.

Code Modernization and Refactoring:

  • Replaced usages of the deprecated Paths.get() with Path.of() for file path handling throughout the codebase, aligning with modern Java best practices.
  • Updated reflection-based object instantiation to use getDeclaredConstructor().newInstance() instead of the deprecated newInstance(). (DefaultClassInitializer.java)
  • Adopted pattern matching and enhanced type inference in several places, such as using instanceof ... var and simplifying lambda expressions.

Minor Cleanups and Consistency Improvements:

  • Removed unused imports and cleaned up code formatting for improved readability and maintainability.

These changes collectively modernize the codebase, improve compatibility with recent Java versions, and enhance maintainability.

Signed-off-by: Haroon Sheikh <haroon.sheikh@sky.uk>
@chadlwilson chadlwilson added the ReleaseCandidate If a PR is tagged with this label, after merging it will be released label Nov 3, 2025
Signed-off-by: Chad Wilson <29788154+chadlwilson@users.noreply.github.com>
Signed-off-by: Chad Wilson <29788154+chadlwilson@users.noreply.github.com>
Signed-off-by: Chad Wilson <29788154+chadlwilson@users.noreply.github.com>
@chadlwilson chadlwilson removed the ReleaseCandidate If a PR is tagged with this label, after merging it will be released label Nov 3, 2025
Signed-off-by: Chad Wilson <29788154+chadlwilson@users.noreply.github.com>
Signed-off-by: Chad Wilson <29788154+chadlwilson@users.noreply.github.com>
@getgauge getgauge deleted a comment from gaugebot bot Nov 3, 2025
Signed-off-by: Chad Wilson <29788154+chadlwilson@users.noreply.github.com>
@chadlwilson chadlwilson merged commit d179db9 into master Nov 3, 2025
3 of 9 checks passed
@chadlwilson chadlwilson deleted the java17-upgrade branch November 3, 2025 09:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants