FORGE-F017: implement discussion-first protocol

This commit is contained in:
rob
2026-12-01 11:12:16 +00:00
parent 97458d1be9
commit b3999ce033
10 changed files with 93 additions and 0 deletions
+29
View File
@@ -0,0 +1,29 @@
"""Focused contract checks for discussion-first behaviour; not LLM behaviour tests."""
import unittest
from pathlib import Path
ROOT = Path(__file__).resolve().parents[1]
class DiscussionFirstContractTests(unittest.TestCase):
def test_context_and_contributor_reference_the_shared_protocol(self):
reference = ROOT / "skills/bortstack-context/references/discussion-first.md"
self.assertTrue(reference.is_file())
context = (ROOT / "skills/bortstack-context/SKILL.md").read_text()
contributor = (ROOT / "skills/bortstack-contributor/SKILL.md").read_text()
self.assertIn("references/discussion-first.md", context)
self.assertIn("discussion-first.md", contributor)
def test_questions_agreement_and_explicit_actions_are_distinct(self):
rules = (ROOT / "skills/bortstack-context/references/discussion-first.md").read_text()
for required in ("ending with `?`", "**Yes** or **No**", "agreement", "ask", "`MISSION-ID engage`", "patch", "latest"):
self.assertIn(required.lower(), rules.lower())
def test_chatgpt_instructions_are_separate_from_codex_skill(self):
instructions = (ROOT / "docs/specifications/discussion-first-protocol.md").read_text()
self.assertIn("ChatGPT project instructions", instructions)
self.assertIn("cannot update ChatGPT project instructions automatically", instructions)
if __name__ == "__main__":
unittest.main()