Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8256649

Parameterized tests must not use instances as parameters

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: openjfx14, openjfx15
    • Fix Version/s: openjfx16
    • Component/s: javafx

      Description

      JDK-8244531 introduced parameterized tests to guard against memoryleaks in in all controls, namely BehaviorMemoryLeakTest and SkinMemoryLeakTest.

      They use control instances as parameters: that's incorrect because the parameter is shared by all test methods. This may lead to inter-test effects when the state of the control is changed. Which accidentally doesn't happen in those tests, they have a single test method each ;)

      The fix is to have control class as parameters and instantiate the control in setup.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                fastegal Jeanette Winzenburg
                Reporter:
                fastegal Jeanette Winzenburg
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: