MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / is_cpp_test_macro

Function is_cpp_test_macro

internal/cbm/extract_defs.c:3512–3516  ·  view source on GitHub ↗

C++/CUDA: true when name is a GoogleTest test-definition macro whose * invocations parse as function definitions with bare-identifier parameters. * Multiple such macros in one file all share the extracted name (e.g. "TEST"), * causing qualified-name collisions and node loss (#1266). */

Source from the content-addressed store, hash-verified

3510 * Multiple such macros in one file all share the extracted name (e.g. "TEST"),
3511 * causing qualified-name collisions and node loss (#1266). */
3512static bool is_cpp_test_macro(const char *name) {
3513 return strcmp(name, "TEST") == 0 || strcmp(name, "TEST_F") == 0 ||
3514 strcmp(name, "TEST_P") == 0 || strcmp(name, "TYPED_TEST") == 0 ||
3515 strcmp(name, "TYPED_TEST_P") == 0;
3516}
3517
3518/* Compose a unique name from a GoogleTest-style macro invocation by appending
3519 * the macro arguments: TEST(Suite, Case) -> "TEST_Suite_Case".

Callers 1

extract_func_defFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected