Repository navigation
Conversation
The end-to-end case runs make_game.main() and expects the Visual Studio library check, but check_windows_sdk goes to check_linux_compiler on Linux and to check_mingw when llvm-mingw sits beside the builder: the fake toolchain was asked for "clang" and the case failed. It now pins LINUX off and bundled_mingw to "", so the route under test is the one it checks, and the test runs in the Linux source-regressions job. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Wpaif
force-pushed
the
fix/cpp-preflight-test
branch
from
November 8, 2026 00:09
6e2ed30 to
667ca67
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
tests/test_cpp_preflight.py's end-to-end case (test_library_failure_stops_check_and_build_before_reading_input) runsmake_game.main()and expects the Visual Studio library check (check_cpp_library). Butcheck_windows_sdkpicks its route from the host:check_linux_compiler, which asks the toolchain forclang; the test's fake toolchain only answersclang++, so the case failed withAssertionError: Unexpected tool requested: clang(and thenFileNotFoundErroron the missing.nup);bundled_mingw()finds llvm-mingw and the route ischeck_mingw, so the case would not test the Visual Studio check there either.The case now pins
make_game.LINUXtoFalseandbundled_mingwto"", so it always exercises the route it asserts on. The other three cases were already host-neutral.CI
The test now passes on Linux with
g++, so I added it to the Linux job ofsource-regressions.yml(python -I -B tests/test_cpp_preflight.py --cxx g++). The docstring called it Windows-only, so if you'd rather keep it out of CI, I'm happy to drop that step.Testing
python -I -B tests/test_cpp_preflight.py --cxx g++on Linux: 4/4 pass (before: 1 failure, 1 error onmain).HOOKSHOT_CPP_TEST_SOURCEwith a copy ofmake_game.pywhosecheck_windows_sdkskipscheck_cpp_library: both subtests fail, so the case still catches the regression it is for.🤖 Generated with Claude Code