Complete independent projection runtime
This commit is contained in:
parent
1134c2d375
commit
f1fabaf0ca
38 changed files with 4907 additions and 87 deletions
|
|
@ -3,6 +3,7 @@ from __future__ import annotations
|
|||
import tempfile
|
||||
import unittest
|
||||
from pathlib import Path
|
||||
from unittest import mock
|
||||
|
||||
from docforge.cli import _parser, _run
|
||||
from docforge.errors import DocForgeError
|
||||
|
|
@ -10,6 +11,28 @@ from docforge.project import Project
|
|||
|
||||
|
||||
class DocForgeOnboardingTests(unittest.TestCase):
|
||||
def test_scaffold_honors_disabled_manual_projection_policy(self) -> None:
|
||||
with tempfile.TemporaryDirectory() as directory:
|
||||
root = Path(directory) / "disabled-render"
|
||||
root.mkdir()
|
||||
arguments = _parser().parse_args(
|
||||
[
|
||||
"--project-root",
|
||||
str(root),
|
||||
"--manual-render-policy",
|
||||
"disabled",
|
||||
"onboard",
|
||||
"--scaffold",
|
||||
]
|
||||
)
|
||||
with mock.patch(
|
||||
"docforge.cli.RenderService.render",
|
||||
side_effect=AssertionError("disabled onboarding must not render"),
|
||||
):
|
||||
result = _run(arguments)
|
||||
self.assertEqual("skipped", result["render"]["state"])
|
||||
self.assertFalse((root / ".docforge/rendered/manual.html").exists())
|
||||
|
||||
def test_assessment_detects_multiple_languages_without_writing(self) -> None:
|
||||
with tempfile.TemporaryDirectory() as directory:
|
||||
root = Path(directory) / "polyglot"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue