generated from coulomb/repo-seed
one time bootstrap path
This commit is contained in:
@@ -42,20 +42,29 @@ def test_deterministic_scanner_extracts_structural_facts(tmp_path):
|
||||
assert languages == {"Python": 2}
|
||||
|
||||
|
||||
def test_scanner_records_scope_with_source_role(tmp_path):
|
||||
def test_scanner_records_intent_and_scope_with_distinct_source_roles(tmp_path):
|
||||
repo = tmp_path / "sample"
|
||||
repo.mkdir()
|
||||
(repo / "INTENT.md").write_text(
|
||||
"# INTENT\n\nProvides planned OIDC profile enforcement.\n",
|
||||
encoding="utf-8",
|
||||
)
|
||||
(repo / "SCOPE.md").write_text(
|
||||
"# SCOPE\n\n## One-liner\n\nProvides OIDC profile enforcement.\n",
|
||||
"# SCOPE\n\n## One-liner\n\nCurrently provides OIDC profile enforcement.\n",
|
||||
encoding="utf-8",
|
||||
)
|
||||
|
||||
result = DeterministicScanner().scan(repo)
|
||||
|
||||
intent_fact = next(fact for fact in result.facts if fact.kind == "intent")
|
||||
assert intent_fact.name == "INTENT"
|
||||
assert intent_fact.path == "INTENT.md"
|
||||
assert intent_fact.metadata["source_role"] == "intent_summary"
|
||||
|
||||
scope_fact = next(fact for fact in result.facts if fact.kind == "scope")
|
||||
assert scope_fact.name == "SCOPE"
|
||||
assert scope_fact.path == "SCOPE.md"
|
||||
assert scope_fact.metadata["source_role"] == "scope_summary"
|
||||
assert scope_fact.metadata["source_role"] == "derived_scope"
|
||||
|
||||
|
||||
def test_scanner_readme_only_fixture_records_docs_without_interfaces(tmp_path):
|
||||
|
||||
Reference in New Issue
Block a user