On Thu, 19 Feb 2026 07:33:16 GMT, Alan Bateman <[email protected]> wrote:

>> Removed the manual file tidyup on the expectation that jtreg will sort that 
>> all out.
>> Switched to using Utils.createTempFile() while I was there.
>
> test/jdk/tools/jimage/JImageBadFileTest.java line 82:
> 
>> 80:             throws IOException {
>> 81:         int remaining = maxLen >= 0 ? maxLen : Integer.MAX_VALUE;
>> 82:         Path dst = Utils.createTempFile("modules-" + label, "");
> 
> Just curious why this is changed.

It's just the more idiomatic way to make temp files in tests, since it hides 
any semantics related to knowing that the current working directory is the 
correct place for temporary files. Fewer details in the test code itself.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/29783#discussion_r2827045289

Reply via email to