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

summaryrefslogtreecommitdiffhomepage
path: root/src/catch2/internal
diff options
context:
space:
mode:
authorMartin Hořeňovský2022-05-16 11:56:11 +0200
committerMartin Hořeňovský2022-05-16 11:56:21 +0200
commitaf8b54ecd59f8174aaaa97682e3544f2820a0900 (patch)
tree1e9738c570b986822c235917ef20afc5ecb89017 /src/catch2/internal
parent07bec74096d91e68efa97587554004740d9aa32a (diff)
downloadcatch3-af8b54ecd59f8174aaaa97682e3544f2820a0900.tar.gz
Generators now keep track of the index of current element
This might become potentially useful in the future, when we want to provide the ability to forward jump generators, to be able to simply reproduce specific input to a test. I am not yet sure how it would work, but the basic idea is that it could be similar to the `-c` switch for selecting specific `SECTION` in a test case.
Diffstat (limited to 'src/catch2/internal')
-rw-r--r--src/catch2/internal/catch_run_context.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/catch2/internal/catch_run_context.cpp b/src/catch2/internal/catch_run_context.cpp
index 872783c6..7da8f714 100644
--- a/src/catch2/internal/catch_run_context.cpp
+++ b/src/catch2/internal/catch_run_context.cpp
@@ -143,7 +143,7 @@ namespace Catch {
// this generator is still waiting for any child to start.
if ( should_wait_for_child ||
( m_runState == CompletedSuccessfully &&
- m_generator->next() ) ) {
+ m_generator->countedNext() ) ) {
m_children.clear();
m_runState = Executing;
}