Uploaded image for project: 'Code Tools'
  1. Code Tools
  2. CODETOOLS-7903751

Introduce a timing extension for junit tests which prints the time taken for each test method

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Duplicate
    • Icon: P4 P4
    • None
    • None
    • tools
    • None

      As noted in this PR against JDK mainline https://github.com/openjdk/jdk/pull/19627/files#r1637622775, having the ability to print the time taken for each junit test method can be useful. junit provides a way to do that through the use of (junit specific) Extension interface https://junit.org/junit5/docs/current/api/org.junit.jupiter.api/org/junit/jupiter/api/extension/Extension.html. jtreg could implement such an interface and package it to be available through the ServiceLoader mechanism noted there.

      While this is specific to junit, we could also look into making this available for testng tests too, if it provides similar hooks.

            jpai Jaikiran Pai
            jpai Jaikiran Pai
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: