RFR: JDK-8292066 Convert TestInputArgument.sh and TestSystemLoadAvg.sh to java version
Bill Huang
duke at openjdk.org
Mon Aug 29 22:46:05 UTC 2022
On Mon, 29 Aug 2022 21:50:14 GMT, Leonid Mesnik <lmesnik at openjdk.org> wrote:
>> This task converts 2 shell tests to java version.
>> test/java/lang/management/OperatingSystemMXBean/TestSystemLoadAvg.sh
>> test/java/lang/management/RuntimeMXBean/TestInputArgument.sh
>
> test/jdk/java/lang/management/OperatingSystemMXBean/GetSystemLoadAverage.java line 69:
>
>> 67: }
>> 68:
>> 69: @Test(invocationCount = 5, timeOut = 300)
>
> I am not sure it is the correct replacement. Accordingly to TestNG doc the invocationCount = 5 means that TestNG calls the test 5 times. And test fails if any of the invocations fail while the bash script makes 5 attempts and passes if testcase passed in any of them.
Good catch! I've missed the exit statement in the original shell script.
-------------
PR: https://git.openjdk.org/jdk/pull/9848
More information about the serviceability-dev
mailing list