MCPcopy Create free account
hub / github.com/Graphify-Labs/graphify / _calls

Function _calls

tests/test_cpp_receiver_parameters.py:50–60  ·  view source on GitHub ↗
(tmp_path, files: dict[str, str])

Source from the content-addressed store, hash-verified

48
49
50def _calls(tmp_path, files: dict[str, str]):
51 for name, body in files.items():
52 (tmp_path / name).write_text(body, encoding="utf-8")
53 with redirect_stdout(io.StringIO()):
54 r = extract([tmp_path / n for n in files], cache_root=Path(tempfile.mkdtemp()),
55 root=tmp_path, parallel=False)
56 def norm(label):
57 return str(label).strip(".").removesuffix("()")
58 labels = {n["id"]: norm(n["label"]) for n in r["nodes"]}
59 return {(labels.get(e["source"]), labels.get(e["target"]))
60 for e in r["edges"] if e.get("relation") == "calls"}, r
61
62
63def test_every_parameter_form_resolves_like_the_local_does(tmp_path):

Calls 4

extractFunction · 0.90
normFunction · 0.70
itemsMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected