Skip to content

dse120071750/m8m-harness-builder / skills/m8m/m8m-harness-builder/templates

__SKILL_NAME__

Verified

M8M 3.1 product skill whose closed native source compiles into a displayable, executable milestone workflow.

milestone/judge_test_tool.py

View on GitHub
"""Unit test for the __STEP_ID__ gem worker."""

from __future__ import annotations

import importlib.util
import unittest
from pathlib import Path

TOOL_DIR = Path(__file__).resolve().parents[1]
_spec = importlib.util.spec_from_file_location("__STEP_ID___tool", TOOL_DIR / "tool.py")
assert _spec is not None and _spec.loader is not None
tool = importlib.util.module_from_spec(_spec)
_spec.loader.exec_module(tool)


class ToolTests(unittest.TestCase):
    def test_scaffold_requires_implementation_after_typed_request(self) -> None:
        request = {
            "schema": "m8m.milestone_judge_request.v1",
            "milestone_id": "example_ready",
            "attempt": 1,
            "max_attempts": 2,
            "expectation": {
                "schema": "m8m.milestone_expectation.v1",
                "milestone_id": "example_ready",
                "success": "The example is accepted.",
                "output_contract": "example_v1",
                "output_schema_ref": "schemas/example.json",
                "outputs": [],
            },
            "inputs": {},
            "candidate": {"outputs": {}},
        }
        with self.assertRaises(NotImplementedError):
            tool.run(request)

    def test_candidate_control_flag_is_not_a_judge_request(self) -> None:
        with self.assertRaises(ValueError):
            tool.run({"accepted": True, "candidate": {"outputs": {}}})


if __name__ == "__main__":
    unittest.main()
reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis.Stars: 472kUpdated Claude CodeCodexVerifiedInstall
diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness.Stars: 322kUpdated Claude CodeCodexVerifiedInstall
dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependenciesStars: 322kUpdated Claude CodeCodexVerifiedInstall
executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is availableStars: 322kUpdated Claude CodeCodexVerifiedInstall