On Sat, 15 Jun 2024 09:54:38 GMT, SendaoYan <[email protected]> wrote:
>> Hi all,
>> Test
>> `test/langtools/jdk/javadoc/doclet/testIOException/TestIOException.java` run
>> fails with root user privileged. I think it's necessary to skip this
>> testcase when user is root.
>> Why run the jtreg test by root user? It's because during rpmbuild process
>> for linux distribution of JDK, root user is the default user to build the
>> openjdk, also is the default user to run the `make test-tier1`, this PR make
>> this testcase more robustness.
>> The change has been verified, only change the testcase, no risk.
>
> SendaoYan has updated the pull request incrementally with one additional
> commit since the last revision:
>
> delete an extra whitespace
I re-titled the JBS issue, please update this PR title accordingly.
test/langtools/jdk/javadoc/doclet/testIOException/TestIOException.java line 58:
> 56: if(Platform.isRoot() && !tester.isWindows()) {
> 57: throw new SkippedException("root user has privileged will
> make this test fail.");
> 58: }
Suggestion:
if (Platform.isRoot() && !tester.isWindows()) {
throw new SkippedException("root user has privileges that will make
this test fail");
}
var tester = new TestIOException();
-------------
PR Review: https://git.openjdk.org/jdk/pull/19731#pullrequestreview-2123177216
PR Review Comment: https://git.openjdk.org/jdk/pull/19731#discussion_r1642972912