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

Function fixture_file_equals

tests/test_sqlite_writer.c:52–62  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

50}
51
52static int fixture_file_equals(const char *path, const char *expected) {
53 FILE *fp = cbm_fopen(path, "rb");
54 if (!fp) {
55 return 0;
56 }
57 char buf[64] = {0};
58 size_t n = fread(buf, 1, sizeof(buf), fp);
59 int close_rc = fclose(fp);
60 size_t expected_len = strlen(expected);
61 return close_rc == 0 && n == expected_len && memcmp(buf, expected, expected_len) == 0;
62}
63
64static int count_temp_outputs_for(const char *path) {
65 char dir[256];

Callers 1

Calls 2

cbm_fopenFunction · 0.85
freadFunction · 0.85

Tested by

no test coverage detected