Releases: ascopes/java-compiler-testing
v1.0.0-RC1
This is the first release candidate for the v1.0 stable release.
Changes
The aim of this set of changes is to remove all deprecated functionality that has been removed to simplify this API for the vast majority of use cases. I have attempted to ensure all functionality that may still be required in edge cases is still accessible via more explicit method calls.
The details of these changes are az follows:
- Remove deprecated features for v1.0.0 by @ascopes in #395
- Remove 'modules' parameter for JavacCompilersTest and related functionality.
- Remove 'modules' parameter in minSupportedVersion and maxSupportedVersion in JavacJctCompilerImpl.
- Remove deprecated JctCompilers.createPlatformCompiler, as we now just use JctCompilers.newPlatformCompiler instead.
- Remove deprecation warnings around toString in AbstractJctCompiler.
- Remove default override for JctCompilation.getArguments -- this is now a required method to be implemented by custom implementations.
- Move PathRoot.asJar into implementation level. Custom PathRoots must now provide this method explicitly.
- Remove platform classpath features deprecated in #396 -- platform classpath functionality historically was for Java versions prior to Java 11, and is mostly replaced with the system modules mechanism. If you still need to use this, you can use one of the method overrides that consume a Location object instead, passing StandardLocation.PLATFORM_CLASS_PATH as the Location parameter.
- Remove obscure deprecated methods in JctFileManager and Workspace classes as part of GH-417. If you still need to use this, you can use one of the method overrides that consume a Location object instead, passing StandardLocation as the Location parameter. The following methods have been affected:
- Removed JctFileManager.getNativeHeaderOutputGroup
- Removed JctFileManager.getUpgradeModulePathGroup
- Removed JctFileManager.getSystemModulesGroup
- Removed JctFileManager.getPatchModulePathGroup
- Removed Workspace.addNativeHeaderOutputPackage
- Removed Workspace.addNativeHeaderOutputModule
- Removed Workspace.addUpgradeModulePathModule
- Removed Workspace.addSystemModulePathModule
- Removed Workspace.addPatchModulePathModule
- Removed Workspace.createNativeHeaderOutputPackage
- Removed Workspace.createNativeHeaderOutputModule
- Removed Workspace.createUpgradeModulePathModule
- Removed Workspace.createSystemModulePathModule
- Removed Workspace.createPatchModulePathModule
- Removed Workspace.getNativeHeaderOutputPackages
- Removed Workspace.getNativeHeaderOutputModules
- Removed Workspace.getUpgradeModulePathModules
- Removed Workspace.getSystemModulePathModules
- Removed Workspace.getPatchModulePathModules
- Removed Workspace.getNativeHeaderOutputModule
- Removed Workspace.getUpgradeModulePathModule
- Removed Workspace.getSystemModulePathModule
- Removed Workspace.getPatchModulePathModule
- Remove deprecated RamFileSystemProvider mechanism
- Fix MemoryFileSystemProviderImpl to make use of the provided file system name
- Fix a couple of bugs regarding MemoryFileSystemProvider disallowing specific
characters in file system names. - Remove JctCompilationAssert.generatedHeaders - If you still need to use this, you can use one of the method overrides that consume a Location object instead, passing StandardLocation as the Location parameter.
- Remove methods deprecated in GH-447 for JctCompilationAssert - all of these have new methods in the same class that are named consistently with the rest of this library. Check the documentation for JctCompilationAssert to see what is available.
- Removed JctCompilationAssert.classOutput
- Removed JctCompilationAssert.sourceOutput
- Removed JctCompilationAssert.classPath
- Removed JctCompilationAssert.sourcePath
- Removed JctCompilationAssert.moduleSourcePath
- Removed JctCompilationAssert.modulePath
- Remove deprecated PathFileObject.getFullPath, which has been replaced with PathFileObject.getAbsolutePath
- Make PathFileObject into an interface, and make the existing implementation become part of the internal API.
Full Changelog: v0.7.3...v1.0.0-RC1
v0.7.3
What's Changed
-
Implement path file object assertion tests by @ascopes in #469
- This deprecates PathFileObject#getFullPath. Use PathFileObject#getAbsolutePath instead. The former will be removed in v1.0.0.
-
Bump gmavenplus-plugin from 2.1.0 to 3.0.0 by @dependabot in #472
-
Bump lombok from 1.18.26 to 1.18.28 by @dependabot in #473
-
Bump maven-checkstyle-plugin from 3.2.2 to 3.3.0 by @dependabot in #471
-
Bump avaje-inject.version from 9.1 to 9.2 by @dependabot in #470
-
Bump auto-service from 1.0.1 to 1.1.0 by @dependabot in #474
-
Bump maven-source-plugin from 3.2.1 to 3.3.0 by @dependabot in #475
Full Changelog: v0.7.2...v0.7.3
v0.7.2
What's Changed
- Improve error messages in assertions for trace diagnostics and stack trace elements.
- Fix bug that raised a NullPointerException when asserting on null TraceDiagnostic objects
Full Changelog: v0.7.1...v0.7.2
v0.7.1
v0.7.0
What's Changed
Removed JIMFS as the underlying RAM file system implementation and switched to using memoryfilesystem. This shouldn't break any existing code, but I have made it a minor release bump just to flag this as a major internal change.
Please raise an issue or discussion for any bugs or queries.
Changelog
- Build on MacOS 13 rather than MacOS 12 by @ascopes in #449
- Fix ShellCheck warnings on Sonatype Lift by @ascopes in #452
- Request that Sonatype Lift ignore false positives by @ascopes in #453
- Replace JIMFS with MemoryFileSystem by @ascopes in #451
- Bump maven-surefire-plugin from 3.0.0 to 3.1.0 by @dependabot in #459
- Bump maven-gpg-plugin from 3.0.1 to 3.1.0 by @dependabot in #458
- Bump groovy from 4.0.11 to 4.0.12 by @dependabot in #457
- Bump maven-failsafe-plugin from 3.0.0 to 3.1.0 by @dependabot in #455
- Bump checkerframework.version from 3.33.0 to 3.34.0 by @dependabot in #454
Full Changelog: v0.6.4...v0.7.0
v0.6.4
v0.6.3
What's Changed
- Updating maven for version 3.9.1 by @FilipeRamos92 in #427
- Bump junit-bom from 5.9.2 to 5.9.3 by @dependabot in #443
- Task/package container group assert tests by @ascopes in #444
- Build on released JDK 20 by @ascopes in #445
- Enable JDK 21 builds by @ascopes in #310
- Improvements to assertion error messages
New Contributors
- @FilipeRamos92 made their first contribution in #427
Full Changelog: v0.6.2...v0.6.3
v0.6.2
v0.6.1
Some minor QA fixes.
- Fixes to error messages in assertions
- Fixes and improvements to logging output
Full Changelog: v0.6.0...v0.6.1
v0.6.0
What's Changed
New features
API changes and improvements
- OutputContainerGroups can now only hold a single package, since JSR-199 does not provide a clear API to handle more than one package in an output group. This does not affect modules. (@ascopes, see 27eaf51)
- Improved internal error messages that get thrown to the user if various invalid file-system states occur (@ascopes, see 851d9a4)
- Fuzzy string handling in assertions for files and modules has been reworked, fixing several issues where FileSystemException and similar exception types could be raised when JARs and archives were on a location with non-archive directory paths. The error output has also been totally rewritten to be clearer and simpler. (@ascopes, see 859a660)
- Fixes to documentation, adding missing detail and fixing mistakes in multiple places.
Deprecated features
For a full list of deprecated features, view the deprecation page in the JavaDocs here.
- All features relating to the platform/bootstrap classpath have been deprecated and will be removed in v1.0.0. This has been done since the platform class path has been mostly replaced by the JPMS mechanisms from Java 9 onwards, and using this parameter is buggy and can lead to confusing behaviour. If you need to use this feature still, check the documentation for alternatives. No actual functionality is being restricted by this change, only API shortcuts. (@ascopes, see 68fadf2)
- Features relating to lesser-used locations have been deprecated and will be removed in v1.0.0, instead, you should access the locations as documented (e.g.
addModule(StandardLocation.PATCH_MODULE_PATH)
rather thanaddPatchModulePathModule
). This has been done to reduce the noise in the API and keep things simple for the majority of use cases. No actual functionality is being restricted by this change, only API shortcuts. This affects:SYSTEM_MODULES
,PATCH_MODULE_PATH
,UPGRADE_MODULE_PATH
,NATIVE_HEADER_OUTPUTS
. (@ascopes, see 4e37df1 and a5369d0). - RamFileSystemProvider has been deprecated and will be removed in v1.0.0. No mechanism exists to replace this functionality. This has been removed as it is not needed for the vast majority of usecases, and only exists to further confuse usage. If you do somehow need to use this mechanism, please open an issue so I can discuss it and understand the reasoning behind it more clearly. (@ascopes, see 5b5a3df)
Internal changes
- New internal API for listing internal path roots for archives such as JARs - (@ascopes, see 2e47542)
- Testing against newer releases of Spring, Avaje, Micronaut, groovy.
- Internal test pack fixes for https://youtrack.jetbrains.com/issue/IDEA-317391.
- Internal test pack fixes for some issues regarding concurrency in JUnit-related tests.
Full Changelog: v0.5.0...v0.6.0
Future changes
v1.0.0
A branch and draft PR has been opened to hold changes that will be made for v1.0.0. You can review this at #395
Eclipse Compiler for Java
I have began to work on re-integrating ECJ support into JCT. Right now I am firefighting with several major bugs that I was previously aware of that reside within the ECJ codebase. A preview of potential changes can be reviewed at #422.
Java 21 support
I am still waiting on Mockito to provide Java 21 support via the version of ByteBuddy that is bundled. JaCoCo has pushed a new version recently (v0.8.9) that supports Java 20 and Java 21 bytecode, which is also a prerequisite. As a result of this, the code in this release also now runs JaCoCo across Java 20 builds correctly.
Class file and stacktrace assertions
I am still waiting on some PRs for stacktrace assertions and reflective assertions across classes and classloaders to be merged in AssertJ-Core. Once these become available, then I will upgrade JCT and bundle them in a new release.
JIMFS guava-related security warnings.
The CVEs reported in Google Guava that are pulled in via JIMFS do not actively impact JCT in any way (JCT does not use Guava directly, and tempfile handling in JIMFS will remain limited to the permissions of the active user anyway). I am still waiting on Google's team to push a new release for JIMFS, which should include an update to Google Guava, as well as improvements to support JPMS properly.