[jdk17u-dev] RFR: 8286045: Use ForceGC for cleaner test cases

Matthias Baesken mbaesken at openjdk.org
Fri Dec 15 13:36:45 UTC 2023


On Sat, 25 Nov 2023 18:45:24 GMT, Andrew John Hughes <andrew at openjdk.org> wrote:

> [JDK-8286045](https://bugs.openjdk.org/browse/JDK-8286045) is a test fix which aims to make GC usage within test cases more reliable by using the `ForceGC` library added by [JDK-8238358](https://bugs.openjdk.org/browse/JDK-8238358).
> 
> It adjusts three test cases:
> 
> * `test/jdk/javax/security/auth/callback/PasswordCallback/CheckCleanerBound.java`
> * `test/jdk/sun/security/jgss/GssContextCleanup.java`
> * `test/jdk/sun/security/jgss/GssNameCleanup.java`
> 
> The two `jgss` tests are introduced by a finalization cleanup, [JDK-8284490](https://bugs.openjdk.org/browse/JDK-8284490): "Remove finalizer method in java.security.jgss", which is not in 17u, so this backport only includes the changes to `CheckCleanerBound.java`, which was introduced in the 2023-10 security update.
> 
> The changes to `CheckCleanerBound.java` apply cleanly, but the test still fails as `CheckCleanerBound.java` never received the changes in the backport of [JDK-8285796](https://bugs.openjdk.org/browse/JDK-8285796) as this backport was introduced in 17u about a week before `CheckCleanerBound.java`. With that additional fragment cherry-picked from the trunk version of 8285796, the test passes.
> 
> Finally, we drop the `ProblemList.txt` addition made by [JDK-8285785](https://bugs.openjdk.org/browse/JDK-8285785) as the test now passes.

Marked as reviewed by mbaesken (Reviewer).

-------------

PR Review: https://git.openjdk.org/jdk17u-dev/pull/1987#pullrequestreview-1784032620


More information about the jdk-updates-dev mailing list