RFR: 8355578: [java.net] Use @requires tag instead of exiting based on "os.name" property value [v2]

Volkan Yazici vyazici at openjdk.org
Wed May 7 11:52:21 UTC 2025


On Wed, 7 May 2025 11:29:11 GMT, Daniel Fuchs <dfuchs at openjdk.org> wrote:

>> Volkan Yazici has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Document `@requires` rationale with `@comment`
>>   
>>   Co-authored-by: Daniel Fuchs <67001856+dfuch at users.noreply.github.com>
>
> test/jdk/java/net/MulticastSocket/PromiscuousIPv6.java line 27:
> 
>> 25:  * @test
>> 26:  * @bug 8215294
>> 27:  * @requires os.family == "linux" & !(os.version ~= "3\\.10\\.0.*")
> 
> Would that match 13.10.01?

No.

Adding `@requires os.family ~= "inux"` causes a test to be discarded on my (Linux) system. That is, the pattern is implicitly wrapped with `^` and `$` directives. Whereas `@requires os.family ~= "linux"` causes the test to get executed.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/24997#discussion_r2077450781


More information about the net-dev mailing list