(result: dict, source: str, target: str, relation: str = "imports_from")
| 22 | |
| 23 | |
| 24 | def _has_edge(result: dict, source: str, target: str, relation: str = "imports_from") -> bool: |
| 25 | expected = (_file_node_id(Path(source)), _file_node_id(Path(target)), relation) |
| 26 | actual = { |
| 27 | (edge["source"], edge["target"], edge["relation"]) |
| 28 | for edge in result["edges"] |
| 29 | } |
| 30 | return expected in actual |
| 31 | |
| 32 | |
| 33 | def test_import_require_relative_emits_file_edge(tmp_path: Path): |
no test coverage detected