Skip to content

Build and run the C tests on Windows CI - #1232

Merged
redboltz merged 3 commits into
msgpack:c_masterfrom
redboltz:fix_appveyor_test
Nov 20, 2026
Merged

redboltz merged 3 commits into
msgpack:c_masterfrom
redboltz:fix_appveyor_test

Conversation

@redboltz

Copy link
Copy Markdown
Contributor

MSGPACK_BUILD_TESTS defaults to OFF and neither appveyor.yml nor the GitHub Actions windows job turned it on, so ctest reported "No tests were found" and the C tests have never run on MSVC. Enable it, pass -C Release to ctest for the multi-config generator, build the gtest 1.7.0 DLL with the shared CRT, and pick the vcpkg triplet that matches the target architecture.

MSGPACK_BUILD_TESTS defaults to OFF and neither appveyor.yml nor the
GitHub Actions windows job turned it on, so ctest reported
"No tests were found" and the C tests have never run on MSVC.
Enable it, pass -C Release to ctest for the multi-config generator,
build the gtest 1.7.0 DLL with the shared CRT, and pick the vcpkg
triplet that matches the target architecture.
Link gtest statically: the DLL build needs GTEST_LINKED_AS_SHARED_LIBRARY,
which makes the gtest 1.7.0 headers emit C4251/C4275 and fail under /WX.
Guard the 64-bit-only zbuffer size tests with the preprocessor so their
constants do not overflow on 32-bit targets (C4307).
@redboltz
redboltz merged commit 1057173 into msgpack:c_master Nov 20, 2026
19 of 20 checks passed
@redboltz
redboltz deleted the fix_appveyor_test branch November 20, 2026 14:22
@codecov-commenter

Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 63.73%. Comparing base (eabfe29) to head (cebdcc7).
⚠️ Report is 29 commits behind head on c_master.
❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@             Coverage Diff              @@
##           c_master    #1232      +/-   ##
============================================
+ Coverage     57.47%   63.73%   +6.26%     
============================================
  Files            10       10              
  Lines          1124     1150      +26     
  Branches        129      142      +13     
============================================
+ Hits            646      733      +87     
+ Misses          478      417      -61     
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants