कंटेंट पर जाएँ
TakoAPI
स्किल्स पर वापस

agents-skill-tdd-helper

cerbug45 द्वारा

CLI Utilities
570clawskills.sh द्वारा बताए गए डाउनलोड
1व्यूज़
0 लाइकइस स्किल को लाइक करने के लिए साइन इन करें
—अभी तक कोई रेटिंग नहीं
आपकी रेटिंग

संक्षिप्त

Lightweight helper to enforce TDD-style loops for non-deterministic agents.

विवरण

यह स्किल क्या करती है

tdd-helper wraps task execution to enforce test-first discipline. It refuses to run production code if tests are absent or failing, and can optionally treat lint warnings as errors. Configuration is via environment variables or a JSON file.

Unlike invoking pytest directly, it enforces the test-first constraint at the process level, so agents cannot bypass the cycle even when code is generated dynamically.

इसे कब इस्तेमाल करें

  • Blocking agent-generated code from running before tests pass
  • Enforcing test presence in automated pipelines
  • Running pytest suites before executing generated scripts
  • Treating lint warnings as hard errors in CI workflows
  • Guarding non-deterministic agent outputs with regression checks

उदाहरण वर्कफ़्लो

इनपुट

User asks: run my_script.py, but only if all tests in tests/ pass

एजेंट
  1. 1

    Agent calls tdd.py with --tests tests/ --run 'python my_script.py'

  2. 2

    tdd.py checks that tests/ exists and contains test files

  3. 3

    tdd.py runs pytest on the test suite

  4. 4

    If any test fails or no tests are found, tdd.py exits with an error and blocks execution

  5. 5

    If all tests pass, tdd.py runs my_script.py

आउटपुट

my_script.py executes only after the full test suite passes

इंस्टॉलेशन

clawhub install cerbug45/agents-skill-tdd-helper

CLI कमांड चलाएँ, या प्रॉम्प्ट को Claude Code, Cursor, Codex या जो भी कोडिंग एजेंट आप इस्तेमाल करते हैं उसमें पेस्ट करें।

लिंक