Buckets:
AnonymousSpottedToad/candidate_bucket / codebase /python /ViperJuice_Code-Index-MCP /tests /docs /test_p6b_sl2.py
| import pathlib | |
| import re | |
| ARCH_PATH = pathlib.Path(__file__).parents[2] / "specs" / "active" / "architecture.md" | |
| def _mermaid_bodies(text: str) -> str: | |
| """Concatenate bodies of all ```mermaid ... ``` blocks.""" | |
| return "\n".join(re.findall(r"```mermaid\s*(.*?)```", text, re.DOTALL)) | |
| def test_architecture_c4_nodes(): | |
| text = ARCH_PATH.read_text() | |
| bodies = _mermaid_bodies(text) | |
| for node in [ | |
| "RepoContext", | |
| "StoreRegistry", | |
| "RepositoryRegistry", | |
| "MultiRepositoryWatcher", | |
| "RefPoller", | |
| "HandshakeGate", | |
| ]: | |
| assert node in bodies, f"Mermaid diagrams missing node: {node}" | |
| def test_architecture_sandbox_and_caveat(): | |
| text = ARCH_PATH.read_text() | |
| assert "path_outside_allowed_roots" in text, "Missing sandbox error code" | |
| lower = text.lower() | |
| assert "enhanceddispatcher" in lower, "Missing EnhancedDispatcher in dependability caveat" | |
| assert "tree-sitter" in lower, "Missing tree-sitter in dependability caveat" | |
Xet Storage Details
- Size:
- 1.01 kB
- Xet hash:
- bc0bc999d15144c5121e6ff4e20e915f434b131804141dfed172b670110454b1
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.