RFR: 8350098: jpackage test lib erroneously will run methods without @Test annotation as tests

Alexey Semenyuk asemenyuk at openjdk.org
Fri Feb 14 14:38:44 UTC 2025


Don't consider functions without `jdk.jpackage.test.Annotations.Test` annotation as tests.

Additionally, enhance the functionality of `jdk.jpackage.test.Annotations.ParameterSupplier` annotation: make an empty string the default value. If the method name is empty (the default annotation value), then the name of the parameter supplier method is the same as the name of the annotated method. E.g.: `@Test @ParameterSupplier public void testInteger(int v)` is equivalent to `@Test @ParameterSupplier("testInteger") public void testInteger(int v)`.

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

Commit messages:
 - Fix javac error
 - Merge branch 'decouple-junit' into decouple-fix-annotations
 - Merge branch 'master' into decouple-junit
 - Remove redundant "return"
 - Merge branch 'decouple-junit' into decouple-fix-annotations
 - Remove TKit.assertEquals(boolean) and TKit.assertNotEquals(boolean). They belong to different branch
 - Merge branch 'decouple-junit' into decouple-fix-annotations
 - Minor
 - Fix typo
 - Revert "Undo unrelated change"
 - ... and 8 more: https://git.openjdk.org/jdk/compare/db42a48d...1247c84b

Changes: https://git.openjdk.org/jdk/pull/23632/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=23632&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8350098
  Stats: 65 lines in 4 files changed: 43 ins; 10 del; 12 mod
  Patch: https://git.openjdk.org/jdk/pull/23632.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/23632/head:pull/23632

PR: https://git.openjdk.org/jdk/pull/23632


More information about the core-libs-dev mailing list