Skip to content

Commit f6ee7f5

Browse files
authored
Merge 2540a8f into sapling-pr-archive-ktf
2 parents b719d26 + 2540a8f commit f6ee7f5

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

Framework/Foundation/test/test_SignpostLogger.cxx

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,4 +63,11 @@ int main(int argc, char** argv)
6363
O2_SIGNPOST_ID_GENERATE(idStacktrace, SignpostStacktrace);
6464
O2_LOG_ENABLE(SignpostStacktrace);
6565
O2_SIGNPOST_EVENT_EMIT_ERROR(SignpostStacktrace, idStacktrace, "Test category", "An error with stacktrace %d \n", 1);
66+
// Test actions associtated to a given debug stream.
67+
static bool testMustCall = false;
68+
static bool testMustNotCall = false;
69+
O2_SIGNPOST_ACTION(SignpostStacktrace, [](void *) { testMustCall = true; });
70+
O2_LOG_DISABLE(SignpostStacktrace);
71+
O2_SIGNPOST_ACTION(SignpostStacktrace, [](void *) { testMustNotCall = true; });
72+
return testMustCall && (!testMustNotCall) ? 0 : 1;
6673
}

0 commit comments

Comments
 (0)