Files
doc-forge/tests/renderers/mcp/test_mcp_content.py
Vishesh 'ironeagle' Bangotra 06ffd2febd chore(release): 0.0.7
Squash-merge lib-standardisation: adopt repo standards across packaging,
tooling, docs, and CI.

- standardize pyproject.toml (canonical packaging, lint config, extras, GSDFC pydoclint)
- add py.typed marker, modernize type hints and Google-style docstrings
- nest generated docs under docs/lib and docs/mcp; add hand-written wiki
- adopt standard Type A PyPI CI pipeline (tag==version guard + quality gate)
- promote generated CHANGELOG.md; bump version to 0.0.7
2026-10-17 02:16:44 +05:30

22 lines
561 B
Python

import json
from pathlib import Path
from docforge import MCPRenderer
from docforge.models import Module, Project
def test_mcp_file_content(tmp_path: Path):
project = Project("testpkg")
project.add_module(Module("testpkg.mod"))
out_dir = tmp_path / "mcp"
renderer = MCPRenderer()
renderer.generate_sources(project, out_dir)
module_file = out_dir / "modules" / "testpkg.mod.json"
payload = json.loads(module_file.read_text())
assert payload["module"] == "testpkg.mod"
assert payload["content"]["path"] == "testpkg.mod"