From 5a2c23b66d2c82954fd265e39c2e28d73ef3eae7 Mon Sep 17 00:00:00 2001 From: Asgeir Frimannsson Date: Mon, 23 Nov 2026 23:45:15 +0100 Subject: [PATCH] Accept both wordings of kapi's missing Windows build message The Windows jobs assert that a default bowrain install fails because no Windows build is listed. kapi up to 1.4.0-rc5 words that refusal as `no version of plugin "bowrain" ... for platform windows/`; later versions name the deciding reason, `plugin "bowrain" has no build for windows/` (neokapi/neokapi#3834). The assertion accepts either and still fails on any other failure and on a successful install. Checked with a stub kapi: both wordings pass; "needs a newer kapi", a network error and a successful install each fail. Co-Authored-By: Claude Fable 5.2 Claude-Session: https://claude.ai/code/session_01GtGobCdyR3d9yLXAfX9jsr --- test/plugins/windows-unlisted.sh | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/test/plugins/windows-unlisted.sh b/test/plugins/windows-unlisted.sh index 7ef9e59..b8f9e6f 100755 --- a/test/plugins/windows-unlisted.sh +++ b/test/plugins/windows-unlisted.sh @@ -14,7 +14,18 @@ if [ "${rc}" -eq 0 ]; then echo "::error::bowrain installed on Windows, so a Windows build is listed again. Restore the default plugins input in the Windows jobs and delete test/plugins/windows-unlisted.sh." exit 1 fi -if ! grep -q 'no version of plugin "bowrain"' <<< "${out}" || ! grep -q 'for platform windows/' <<< "${out}"; then +# kapi words this refusal in one of two ways. Up to 1.4.0-rc5 it prints +# `no version of plugin "bowrain" ... for platform windows/`. Later +# versions name the deciding reason: `plugin "bowrain" has no build for +# windows/`. Any other failure (the network, a kapi too old for every +# listed version) is not the state this script asserts. +earlier() { + grep -q 'no version of plugin "bowrain"' <<< "${out}" && grep -q 'for platform windows/' <<< "${out}" +} +later() { + grep -q 'plugin "bowrain" has no build for windows/' <<< "${out}" +} +if ! earlier && ! later; then echo "::error::bowrain failed to install on Windows for a reason other than a missing Windows build." exit 1 fi