RFR: 8361894: sun/security/krb5/config/native/TestDynamicStore.java ensure that the test is run with sudo [v2]
Mikhail Yankelevich
myankelevich at openjdk.org
Tue Jul 15 14:10:20 UTC 2025
On Tue, 15 Jul 2025 11:35:21 GMT, Matthew Donovan <mdonovan at openjdk.org> wrote:
>> Mikhail Yankelevich has updated the pull request incrementally with one additional commit since the last revision:
>>
>> checking for root user automatically
>
> test/jdk/sun/security/krb5/config/native/TestDynamicStore.java line 60:
>
>> 58:
>> 59: // Show a popup to remind to run this test as sudo user
>> 60: PassFailJFrame.builder()
>
> Using pass/fail in this instance is a little confusing.
>
> Because this test runs on mac can you just check the `user.name` property? A quick, simple test shows that when java is run with `sudo`, the property returns "root". This way, the person running the test isn't constantly faced with a dialog box.
I agree. I think changing this so this is only shown if `user.name` is not `root` will be a better solution. Done in next commit.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/26293#discussion_r2207600791
More information about the security-dev
mailing list