RFR: 8378163: test/jdk/java/net/httpclient/*.java: convert tests that use ITestContext to JUnit [v2]
Daniel Fuchs
dfuchs at openjdk.org
Thu Feb 19 14:33:42 UTC 2026
> This is a first step that converts all tests directly located in the test/jdk/java/net/httpclient directory and which depend on ITestContext (a TestNG API) to use JUnit instead.
>
> Usage of ITestContext is replaced by registering a TestWatcher which can make JUnit stop at the first failure.
> The proposed change is mostly mechanical - with the exception of SpecialHeadersTest which is now also testing HTTP/3.
> Some logging in a few of the tests has also been improved.
>
> This is a test change only.
Daniel Fuchs has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains three additional commits since the last revision:
- Remove Lifecycle.PER_CLASS
- Merge branch 'master' into ITestContext-httpclient-8378163
- 8378163: test/jdk/java/net/httpclient/*.java: convert tests that use ITestContext to JUnit
-------------
Changes:
- all: https://git.openjdk.org/jdk/pull/29786/files
- new: https://git.openjdk.org/jdk/pull/29786/files/fa87488c..e3fb24b4
Webrevs:
- full: https://webrevs.openjdk.org/?repo=jdk&pr=29786&range=01
- incr: https://webrevs.openjdk.org/?repo=jdk&pr=29786&range=00-01
Stats: 75841 lines in 167 files changed: 31950 ins; 31464 del; 12427 mod
Patch: https://git.openjdk.org/jdk/pull/29786.diff
Fetch: git fetch https://git.openjdk.org/jdk.git pull/29786/head:pull/29786
PR: https://git.openjdk.org/jdk/pull/29786
More information about the net-dev
mailing list