On 01/11/21 7:26 am, Jaikiran Pai wrote:
Hello Alan,
On 01/11/21 1:03 am, Alan Bateman wrote:
On Fri, 29 Oct 2021 04:19:21 GMT, Jaikiran Pai <j...@openjdk.org> wrote:
Do you mean the jtreg `driver` style this test is using? I used it
because it was necessary to compare output (the hashCode value)
between multiple JVM runs. I use the `driver` along with the
`ProcessBuilder` to capture the output between multiple JVM runs and
compare those.
No, I mean the test needs cleanup so it can easily be maintained. For
starters I think the main method can take a parameter to indicate its
the child process. HashCodeChecker.main becomes a method in
ModuleDescriptorHashCodeTest. You'll see several examples of this in
the test suite.
I looked around some existing tests and I could find some which have a
"realMain" and a "main" methods. But in all such test cases, the
"realMain" is just called as a method within the same process. So I
guess that's not the one you meant. I'll look around some more to try
and find the expected style for such child processes.
I think I might have understood what you meant. I have now updated the
PR to restructure the test case accordingly. Please let me know if this
looks fine or if this isn't what you meant.
-Jaikiran