On Tue, 25 Nov 2025 03:58:17 GMT, Alexander Matveev <[email protected]>
wrote:
> Added following tests:
> - Verify mac app store PKG doesn't have scripts (added to
> `PkgScriptsTest.java`).
> - `--launcher-as-service` ignored for mac app store PKG (added to
> `ServiceTest.java`).
> - `--launcher-as-service` for additional launcher ignored for mac app store
> PKG (added to `ServiceTest.java`).
test/jdk/tools/jpackage/macosx/PkgScriptsTest.java line 171:
> 169: }
> 170:
> 171: void verify(JPackageCommand cmd, boolean exists) {
What is the semantics of the "exists" parameter? Does it apply to the script or
to the response file? It is confusing. I suggest moving it inside of the
function:
void verify(JPackageCommand cmd) {
var scriptsEnabled = !cmd.hasArgument("--mac-app-store");
if (cmd.isPackageUnpacked()) {
role.verifyExists(cmd, scriptsEnabled);
} else if (scriptsEnabled) {
TKit.assertFileExists(responseFilePath(cmd));
} else {
TKit.assertPathExists(responseFilePath(cmd), false);
}
}
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/28487#discussion_r2560728515