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

Function validate_native_errors

tests/test_coverage_children.py:256–270  ·  view source on GitHub ↗
(stderr, expected_paths)

Source from the content-addressed store, hash-verified

254
255
256def validate_native_errors(stderr, expected_paths):
257 found = set()
258 for line in stderr.splitlines():
259 if line.startswith("coverage child fixture failed:") or line.startswith("coverage profile write failed:"):
260 raise Infrastructure("native fixture or normal-parent coverage failed")
261 if line.startswith("LLVM Profile Error:"):
262 match = re.fullmatch(r'LLVM Profile Error: Failed to write file "(.*)": (.+)', line)
263 if not match:
264 raise Infrastructure("unknown LLVM diagnostic precondition")
265 path = os.path.normpath(match.group(1))
266 if path not in expected_paths:
267 raise Infrastructure("LLVM write failure did not name an owned obstacle")
268 found.add(path)
269 if found != expected_paths:
270 raise Infrastructure("intended genuine LLVM write failure was not observed")
271
272
273def exact_positive_count(text, function):

Callers 1

run_caseFunction · 0.85

Calls 2

setFunction · 0.85
InfrastructureClass · 0.70

Tested by

no test coverage detected