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

Some HttpClient tests don't report leaks

XMLWordPrintable

    • b21

        many HttpClient tests run TRACKER.check to verify if all resources are collected by GC. If the method detects a leak, it returns an AssertionError object that needs to be thrown by the caller.

        Two tests call TRACKER.check, but do not rethrow the exception:
        test/jdk/java/net/httpclient/ForbiddenHeadTest.java
        test/jdk/java/net/httpclient/ProxySelectorTest.java

        Additionally, ForbiddenHeadTest keeps a reference to the HttpClient, preventing the GC from doing its job.

              djelinski Daniel Jelinski
              djelinski Daniel Jelinski
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: