Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## devel #2541 +/- ##
==========================================
+ Coverage 91.57% 91.58% +0.01%
==========================================
Files 183 183
Lines 7564 7564
==========================================
+ Hits 6926 6927 +1
+ Misses 638 637 -1 🚀 New features to boost your workflow:
|
|
Is there anything I should do here? |
|
Hi, sorry for taking so long. Your PR happens to be in the goldilocks zone of not being good enough to approve outright, not being bad enough to reject and the subject matter not being interesting enough to prioritize (small doc update versus Anyway, I think the PR should be split into two, so they can progress separately. I recommend moving the lambda part into its own PR (I'll leave some notes on that separately), and leaving the include docs in this one. |
| } | ||
| ``` | ||
| [godbolt](https://catch2.godbolt.org/z/ebdr9vKcj) | ||
|
|
There was a problem hiding this comment.
This shows, but doesn't explain to non-experts, an important feature: the fact that assertions can happen outside the TEST_CASE.
There is also something interesting to be said about lambdas specifically: how do their capture lists behave across multiple invocations (due to SECTIONs).
So I would like to see a bit of text first explaining assertions in separate functions, then another piece about lambdas.
| ## Natural Expressions | ||
| ```cpp | ||
| #include <catch2/catch_test_macros.hpp> | ||
| ``` |
There was a problem hiding this comment.
I like this format for larger sections (ideally with their own headings) 👍
| ```cpp | ||
| #include <catch2/generators/catch_generators_random.hpp> | ||
| ``` | ||
|
|
There was a problem hiding this comment.
But I don't like it for lists, and I don't like adding new sections just to have the include paths in them.
There was a problem hiding this comment.
I think there is enough extra information to be mentioned about the random generators (e.g. their repeatability guarantees) that this subheading could be filled out to be meaningful.
However, I don't see this also being true for the range generator, so we will need a different format for inline markings of things in lists.
| ### Range generators | ||
| ```cpp | ||
| #include <catch2/generators/catch_generators_range.hpp> | ||
| ``` |
There was a problem hiding this comment.
Because the text below now reads as part of the range generators.
Description
Adding includes to the documentation and a basic test case with a lambda.
GitHub Issues
#2519 - Added headers for parts of Catch2 that I am aware of.
#2513 - Basic test case with a lambda.