On Mon, 11 May 2026 21:59:05 GMT, Ashay Rane <[email protected]> wrote:

> The powershell binary is required to run these tests but in the GitHub
> workflow that runs tests (specifically, in test.yml), we reset the PATH
> environment variable on Windows, causing the GitHub workflow to fail if
> you run these tests.  The tests pass locally since local test runs don't
> modify PATH.
> 
> To make these tests pass in GitHub workflows, this patch updates the
> tests to refer to PowerShell using the canonical path on Windows.  See
> https://github.com/raneashay/openjdk-jdk/actions/runs/25680763981/job/75401590988
> for a sample workflow run of the tier2 part1 tests, which include the
> CngCipher and DupAlias tests.
> 
> ---------
> - [x] I confirm that I make this contribution in accordance with the [OpenJDK 
> Interim AI Policy](https://openjdk.org/legal/ai).

Changes requested by myankelevich (Committer).

test/jdk/sun/security/mscapi/CngCipher.java line 2:

> 1: /*
> 2:  * Copyright (c) 2021, Oracle and/or its affiliates. All rights reserved.

Suggestion:

 * Copyright (c) 2021, 2026, Oracle and/or its affiliates. All rights reserved.

test/jdk/sun/security/mscapi/CngCipher.java line 77:

> 75:     }
> 76: 
> 77:     static String powershellPath() {

This method is duplicated in both files and might need to be used in others in 
the future. I'd personally put it in the `jdk/test/lib/security` instead and 
call as a library. What do you think?

test/jdk/sun/security/mscapi/DupAlias.java line 2:

> 1: /*
> 2:  * Copyright (c) 2023, Oracle and/or its affiliates. All rights reserved.

Suggestion:

 * Copyright (c) 2023, 2026, Oracle and/or its affiliates. All rights reserved.

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

PR Review: https://git.openjdk.org/jdk/pull/31127#pullrequestreview-4272345374
PR Review Comment: https://git.openjdk.org/jdk/pull/31127#discussion_r3226471142
PR Review Comment: https://git.openjdk.org/jdk/pull/31127#discussion_r3226460969
PR Review Comment: https://git.openjdk.org/jdk/pull/31127#discussion_r3226469914

Reply via email to