On Wed, 8 Feb 2023 08:14:33 GMT, Alan Bateman <al...@openjdk.org> wrote:
>> The non-hotspot tests integrated with JEP 425/428 were mostly TestNG tests. >> We'd like to convert these JUnit in the main line in advance of other >> updates to these tests in 21. The changes are mostly mechanical and trivial: >> >> - BeforeClass/AfterClass changed to static BeforeAll/AfterAll methods >> - Tests using data providers are changed to parameterized tests >> - The order of the parameters to assertEquals are swapped so that the >> expected result is the first parameter >> - Usages of expectThrows are changed to assertThrows >> - Tests that threw SkipException are changed to the Assumptions API >> >> There are a small number of drive-by changes to the tests, nothing >> significant, e.g. >> >> - GetStackTrace and ParkWithFixedThreadPool changed from "@run testng" to >> "@run main" as they aren't TestNG tests. >> - A few of the tests in StructuredTaskScopeTest for joinXXX are changed to >> use a CountDownLatch rather than sleeping, as the original tests weren't >> very robust. > > Alan Bateman has updated the pull request with a new target base due to a > merge or a rebase. The pull request now contains five commits: > > - Merge > - Merge > - Fix typos in comments > - GetStackTrace.java test missing @requires vm.continuations > - Initial commit test/jdk/jdk/internal/misc/ThreadFlock/WithScopedValue.java line 48: > 46: > 47: private static Stream<ThreadFactory> factories() { > 48: return Stream.of(Thread.ofPlatform().factory(), > Thread.ofVirtual().factory()); Previously, before this change, the data provided to the test methods, comprised of a virtual ThreadFactory and a `Executors.defaultThreadFactory()`. Is this switch to using a `Thread.ofPlatform().factory()` OK in the context of this test? ------------- PR: https://git.openjdk.org/jdk/pull/12426