Read-only mirrors. Development, issues and pull requests are on GitHub.

summaryrefslogtreecommitdiffhomepage
path: root/docs
diff options
context:
space:
mode:
authorMartin Hořeňovský2023-05-06 11:48:25 +0200
committerMartin Hořeňovský2023-05-06 11:48:41 +0200
commitd84777c9cbf5b1b7d0e9ef2e14606ece254adf7a (patch)
treefcf806ea44c6822ba8202f9ba5a922bab629d2a2 /docs
parent51fdbedd1337955bedc02b570bb2a7fb19061f2e (diff)
downloadcatch3-d84777c9cbf5b1b7d0e9ef2e14606ece254adf7a.tar.gz
Fix assertionStarting events being sent after the expr is evaluated
Closes #2678
Diffstat (limited to 'docs')
-rw-r--r--docs/reporter-events.md12
1 files changed, 6 insertions, 6 deletions
diff --git a/docs/reporter-events.md b/docs/reporter-events.md
index 32a0ae50..015f67be 100644
--- a/docs/reporter-events.md
+++ b/docs/reporter-events.md
@@ -96,12 +96,12 @@ void assertionStarting( AssertionInfo const& assertionInfo );
void assertionEnded( AssertionStats const& assertionStats );
```
-`assertionStarting` is called after the expression is captured, but before
-the assertion expression is evaluated. This might seem like a minor
-distinction, but what it means is that if you have assertion like
-`REQUIRE( a + b == c + d )`, then what happens is that `a + b` and `c + d`
-are evaluated before `assertionStarting` is emitted, while the `==` is
-evaluated after the event.
+The `assertionStarting` event is emitted before the expression in the
+assertion is captured or evaluated and `assertionEnded` is emitted
+afterwards. This means that given assertion like `REQUIRE(a + b == c + d)`,
+Catch2 first emits `assertionStarting` event, then `a + b` and `c + d`
+are evaluated, then their results are captured, the comparison is evaluated,
+and then `assertionEnded` event is emitted.
## Benchmarking events