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

Function _write_path_graph

tests/test_cli_export.py:470–481  ·  view source on GitHub ↗

Write a minimal hand-rolled directed graph.json for path-direction tests.

(tmp_path: Path, nodes: list[str], links: list[dict])

Source from the content-addressed store, hash-verified

468# ── graphify path direction (#2487) ─────────────────────────────────────────
469
470def _write_path_graph(tmp_path: Path, nodes: list[str], links: list[dict]) -> Path:
471 """Write a minimal hand-rolled directed graph.json for path-direction tests."""
472 out = tmp_path / "graphify-out"
473 out.mkdir()
474 (out / "graph.json").write_text(json.dumps({
475 "directed": True,
476 "multigraph": False,
477 "graph": {},
478 "nodes": [{"id": n, "label": n} for n in nodes],
479 "links": links,
480 }))
481 return out
482
483
484def _calls(src: str, tgt: str) -> dict:

Calls

no outgoing calls

Tested by

no test coverage detected