catch2/docs
Keith Stockdale f7cd0ba051
TEST_CASE_PERSISTENT_FIXTURE: A new fixture macro for allowing persistent fixtures throughout a TEST_CASE (#2885)
This PR introduces a new `TEST_CASE` macro called `TEST_CASE_PERSISTENT_FIXTURE`. `TEST_CASE_PERSISTENT_FIXTURE` offers the same functionality as `TEST_CASE_METHOD` except for one difference. The object on which the test method is invoked is only created once for all invocations of the test case. The object is created just after the `testCaseStarting` event is broadcast and the object is destroyed just before the `testCaseEnding` event is broadcast.

The main motivation for this new functionality is to allow `TEST_CASE`s to do expensive setup and teardown once per `TEST_CASE`, without having to resort to abusing event listeners or static function variables with manual initialization.


Implements #1602

---------

Co-authored-by: Martin Hořeňovský <martin.horenovsky@gmail.com>
2024-08-05 17:01:41 +02:00
..
assertions.md Update explanation of REQUIRE_FALSE in docs/assertions.md 2022-10-17 15:13:00 +02:00
benchmarks.md Update sample output in docs/benchmarks.md 2023-09-08 10:04:17 +02:00
ci-and-misc.md [DOC] Replaced broken link (fixes #2770) 2023-12-02 22:05:48 +01:00
cmake-integration.md TEST_CASE_PERSISTENT_FIXTURE: A new fixture macro for allowing persistent fixtures throughout a TEST_CASE (#2885) 2024-08-05 17:01:41 +02:00
command-line.md Improve example for custom options in reporter spec 2024-03-26 23:28:48 +01:00
commercial-users.md Trim superfluous whitespace in docs 2022-10-17 15:02:45 +02:00
comparing-floating-point-numbers.md Update comparing-floating-point-numbers.md 2022-10-29 12:42:45 +02:00
configuration.md Introduce CATCH_CONFIG_PREFIX_MESSAGES to only prefix a few logging related macros. (#2544) 2023-07-19 17:04:43 +02:00
contributing.md Update build instructions in contributing.md 2023-02-22 20:11:45 +01:00
deprecations.md Add SUCCEED and FAIL docs next to SKIP docs 2023-01-12 20:38:58 +01:00
event-listeners.md Trim superfluous whitespace in docs 2022-10-17 15:02:45 +02:00
faq.md v3.5.0 2023-12-11 00:55:40 +01:00
generators.md Mention x87 and ffast-math breaking FP random gen reproducibility 2024-02-19 15:02:11 +01:00
limitations.md Document issue with spaceship operator in assertion and MSVC 2024-02-19 15:02:10 +01:00
list-of-examples.md TEST_CASE_PERSISTENT_FIXTURE: A new fixture macro for allowing persistent fixtures throughout a TEST_CASE (#2885) 2024-08-05 17:01:41 +02:00
logging.md Mention SUCCEED along with FAIL in logging.md 2024-03-29 15:40:18 -05:00
matchers.md Update docs for REQUIRE_THROWS_MATCHES 2024-07-27 14:02:28 +02:00
migrate-v2-to-v3.md Explain TU as translation unit where appropriate 2022-09-03 22:22:10 +02:00
opensource-users.md Add SFML to the list of open source users 2023-05-13 14:34:34 -06:00
other-macros.md TEST_CASE_PERSISTENT_FIXTURE: A new fixture macro for allowing persistent fixtures throughout a TEST_CASE (#2885) 2024-08-05 17:01:41 +02:00
own-main.md Rewrite own-main.md for v3 2021-11-19 15:52:32 +01:00
Readme.md Add SUCCEED and FAIL docs next to SKIP docs 2023-01-12 20:38:58 +01:00
release-notes.md v3.6.0 2024-05-05 20:58:18 +02:00
release-process.md Update release-process.md for v3 2022-01-03 23:30:39 +01:00
reporter-events.md Fix assertionStarting events being sent after the expr is evaluated 2023-05-06 11:48:41 +02:00
reporters.md Fix number of current reporter 2024-02-16 21:29:57 +01:00
skipping-passing-failing.md Fix minor typos in documentation (#2769) 2023-12-10 22:01:13 +01:00
test-cases-and-sections.md Fix minor typos in documentation (#2769) 2023-12-10 22:01:13 +01:00
test-fixtures.md TEST_CASE_PERSISTENT_FIXTURE: A new fixture macro for allowing persistent fixtures throughout a TEST_CASE (#2885) 2024-08-05 17:01:41 +02:00
tostring.md Fix minor typos in documentation (#2769) 2023-12-10 22:01:13 +01:00
tutorial.md Improve tutorial.md with link to two-file setup instructions. 2024-02-19 15:01:14 +01:00
usage-tips.md Fix typos in docs (#2514) 2022-09-09 16:00:39 +02:00
why-catch.md Fix minor typos in documentation (#2769) 2023-12-10 22:01:13 +01:00