Skip to content

Add most tests to CMake build and fix some test dependencies - #158

Merged
mborland merged 5 commits into
boostorg:developfrom
Flamefire:cmake-tests
Sep 13, 2026
Merged

Add most tests to CMake build and fix some test dependencies#158
mborland merged 5 commits into
boostorg:developfrom
Flamefire:cmake-tests

Conversation

@Flamefire

Copy link
Copy Markdown
Contributor

Although BoostTestJamfile is used many tests are not included in the CMake build because they are not of the form run source.cpp ; but specify extra dependencies

I replaced that call by a small Jamfile parser that knows about the dependencies.

This surfaced a few dependency issues in the Jamefile:

  • The dependency on Boost.Random is already set for all targets, so does not need to be added again
  • boost_bind was missing from the math tests although given the C++11 base it could now be eliminated
  • boost_iterator was missing from one test
  • test_random_device was always compiled as static and shared, also compiling all dependencies twice. CI uses ./b2 link=static,shared explicitly which I'd say is a cleaner way to test than basically forcing this

Also a mini-change to avoid the deprecation warning from Boost.Bind

@codecov

codecov Bot commented Sep 8, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 95.79%. Comparing base (21b0544) to head (2a8c4de).

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff            @@
##           develop     #158   +/-   ##
========================================
  Coverage    95.79%   95.79%           
========================================
  Files          117      117           
  Lines         7660     7660           
========================================
  Hits          7338     7338           
  Misses         322      322           
Files with missing lines Coverage Δ
test/test_comp_xoshiro128pp.cpp 100.00% <100.00%> (ø)
test/test_qrng_functions.hpp 100.00% <ø> (ø)

Continue to review full report in Codecov by Harness.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 21b0544...2a8c4de. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@Flamefire
Flamefire force-pushed the cmake-tests branch 3 times, most recently from c32d864 to bf05a11 Compare September 11, 2026 11:41
They overflow the stack due to 2 generator instances using 348kB each, allocated on the stack,
and another 348kB on-stack buffer being used in `seed_array_real`.

@mborland mborland left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks like a lot of overlap with #158, but since that one already has a conflict, I will merge this one.

@mborland
mborland merged commit da7bff5 into boostorg:develop Sep 13, 2026
63 checks passed
@Flamefire
Flamefire deleted the cmake-tests branch September 13, 2026 16:20
@Flamefire

Copy link
Copy Markdown
Contributor Author

This looks like a lot of overlap with #158, but since that one already has a conflict, I will merge this one.

You meant #156? I included this PR there to be able to debug that. Will rebase

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