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

Function test_objc_resolves_self_method_calls

tests/test_languages.py:1132–1139  ·  view source on GitHub ↗

`[self speak]` inside Dog.fetch must produce a calls edge. The method-body second pass was dead code for ObjC because the grammar emits a simple selector as `identifier`, not `selector`/`keyword_argument_list` (#1475).

()

Source from the content-addressed store, hash-verified

1130
1131
1132def test_objc_resolves_self_method_calls():
1133 """`[self speak]` inside Dog.fetch must produce a calls edge. The method-body
1134 second pass was dead code for ObjC because the grammar emits a simple selector
1135 as `identifier`, not `selector`/`keyword_argument_list` (#1475)."""
1136 r = extract_objc(FIXTURES / "sample.m")
1137 nid2label = {n["id"]: n["label"] for n in r["nodes"]}
1138 calls = [nid2label.get(e["target"]) for e in r["edges"] if e["relation"] == "calls"]
1139 assert any(t and "speak" in t for t in calls), calls
1140
1141
1142def test_objc_class_method_labeled_with_plus(tmp_path):

Callers

nothing calls this directly

Calls 2

extract_objcFunction · 0.90
getMethod · 0.45

Tested by

no test coverage detected