Bug fixes: - #52: bundle run-sleep.sh in Claude Code plugin + 4-level fallback - #58: add skillopt-sleep console script entry point in pyproject.toml - #62: filter headless claude -p replay sessions from harvest Plugin sync (Claude Code / Codex / Copilot / OpenClaw): - Document all 22 CLI flags, 7 actions, 4 backends across all SKILL.md files - Document config keys (preferences, gate_mode, dream_rollouts, etc.) - Document memory consolidation (evolve_memory / evolve_skill) - Add schedule/unschedule to all plugins - Copilot MCP: expand schema from 3 → 16 params + schedule tools - OpenClaw: add schedule/unschedule subcommands via shared scheduler Tests: - Cross-plugin parity test (prevents future feature drift) - MCP schema completeness test Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,37 @@
|
||||
"""Tests for the Copilot MCP server schema completeness."""
|
||||
import os
|
||||
import sys
|
||||
import unittest
|
||||
|
||||
# Allow importing from the plugin directory
|
||||
sys.path.insert(0, os.path.join(os.path.dirname(__file__), "..", "plugins", "copilot"))
|
||||
|
||||
|
||||
class TestMcpSchema(unittest.TestCase):
|
||||
def test_schema_includes_all_engine_flags(self):
|
||||
from mcp_server import _TOOL_SCHEMA
|
||||
required_params = {
|
||||
"project", "backend", "scope", "source", "model",
|
||||
"tasks_file", "target_skill_path", "progress",
|
||||
"max_sessions", "max_tasks", "lookback_hours",
|
||||
"auto_adopt", "json", "edit_budget",
|
||||
}
|
||||
schema_props = set(_TOOL_SCHEMA["properties"].keys())
|
||||
missing = required_params - schema_props
|
||||
self.assertEqual(missing, set(), f"MCP schema missing: {missing}")
|
||||
|
||||
def test_all_backends_in_enum(self):
|
||||
from mcp_server import _TOOL_SCHEMA
|
||||
backends = _TOOL_SCHEMA["properties"]["backend"]["enum"]
|
||||
for b in ["mock", "claude", "codex", "copilot"]:
|
||||
self.assertIn(b, backends)
|
||||
|
||||
def test_schedule_tools_exist(self):
|
||||
from mcp_server import TOOLS
|
||||
names = {t["name"] for t in TOOLS}
|
||||
self.assertIn("sleep_schedule", names)
|
||||
self.assertIn("sleep_unschedule", names)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
unittest.main()
|
||||
Reference in New Issue
Block a user