Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

orchestration-test-gen

БесплатноБез исполняемых скриптовНе проверен

Generate AAA orchestration tests (isolated or grouped) for ETL-to-Snowflake elements. Scoped to elements assigned to the current phase in ROADMAP.md. Use when…

sfc-gh-dflippoот sfc-gh-dflippo★ 35 звёзд на GitHub

Об этом скилле

Orchestration Test Generator

Generate and run functional equivalence tests for orchestration SQL (task graphs and stored procedures) based on the original control flow logic in the source definition file. Tests are generated BEFORE fixes are applied, serving as an independent oracle derived from the source-of-truth (the source definition file). All generated test artifacts are stored in <UNIT>/stabilization/tests/orchestration/.

Autonomous mode: When spawned as a team agent, skip all interactive stopping points, make reasonable defaults for user-facing decisions, and document assumptions in the completion report. When done, send a send_message to main summarizing your results, and respond to any shutdown_request with send_message using type: "shutdown_response" and approve: true.

Main Mode (interactive / standalone use)

Tests follow the Arrange-Act-Assert (AAA) pattern with a two-phase Arrange:

  • Arrange:Setup: Create all test objects (DDL) — etl_configuration infrastructure, mock dependency tables, schemas, ACT stored procedures. Run once per test file.
  • Arrange:Seed: Populate all tables with test data — TRUNCATE + INSERT for control variables and synthetic rows. Run before every ACT/ASSERT cycle to reset data to a known state.
  • Act: Extract the task body from the current (unfixed) orchestration SQL, wrap it for standalone execution, and run it against the test environment
  • Assert: Run SQL queries that verify side effects (row counts, column values, variable state) match the expected behavior defined by the source control flow logic

Input

This sub-skill expects:

  • session_status.json — with source_file_path set, pending orchestration elements, and migration_object_path
  • The orchestration .sql file path (from session status orchestration_file field)
  • The source definition file path (from source_file_path in session status)
  • ROADMAP.md — defines phases, element assignments, and test strategies (authored by stabilization)

Prerequisites

  • Python 3.11+ installed
  • The source definition file must be accessible and readable
  • Active Snowflake connection with a warehouse configured
  • The etl_configuration/ directory must exist at <CONVERTED_OUTPUT>/ETL/etl_configuration/ (SnowConvert output root is typically the project snowflake/ directory; legacy trees may use Output/SnowConvert/ETL/etl_configuration/)
  • Snowflake privileges: CREATE TABLE, CREATE FUNCTION, and CREATE PROCEDURE on a user-provided database and schema

Output Location

<UNIT>/stabilization/tests/orchestration/
  <schema>/                         # Snowflake schema tests create objects in (typically public)
    <short_element_name>.sql        # Isolated test (segment after last '.' in session_status name)
    grouped_<group_name>.sql        # Grouped test (shared ARRANGE for group)
    ...
  test_report.md                    # Report consumed by orchestration-fixer

The value of this skill is in the ARRANGE and ASSERT sections — they encode what the element needs (infrastructure, seed data) and what correct behavior looks like (functional equivalence checks from the source definition file). The ACT section is a snapshot of the current orchestration SQL (the baseline). It is updated by the orchestration-fixer during the fix-test loop.

Test Lifecycle

This skill (orchestration-test-gen):
  ARRANGE:SETUP + ARRANGE:SEED + ASSERT written from source definition file (stable, written once)
  ACT extracted from unfixed orchestration SQL (baseline snapshot)
  Execute: ARRANGE:SETUP → ARRANGE:SEED → ACT → ASSERT
  ACT may fail (expected), ASSERT may fail (expected)
  Record baseline failures in test_report.md

Orchestration-fixer uses test file as workbench:
  Fixer modifies ACT in the test file with proposed fix
  First cycle: ARRANGE:SETUP → ARRANGE:SEED → ACT → ASSERT
  Subsequent cycles: ARRANGE:SEED → ACT → ASSERT (SEED resets data)
  If ASSERT fails → iterates (modifies ACT, re-runs SEED → ACT → ASSERT)
  If ASSERT passes → applies proven fix to orchestration SQL file
  Test file now contains the verified fix in its ACT section

Validation:
  Re-runs test file as-is (ARRANGE:SETUP → ARRANGE:SEED → ACT → ASSERT)

Final artifact:
  Test file with fixed ACT + source-derived assertions
  Users can re-run this file at any time to verify functional equivalence

Workflow

Copy this checklist and track your progress:

Orchestration Test Gen Progress:
- [ ] Phase 1: Configure test environment + analyze source definition file and orchestration SQL (phase-scoped)
- [ ] Phase 2: Arrange — generate test infrastructure (isolated or grouped)
- [ ] Phase 3: Assert — generate test assertions
- [ ] Phase 4: Act — build complete test files and execute
- [ ] Phase 5: Report results and write test_report.md

Phase 1: Configure Test Environment and Analyze

Step 1.0: Configure Test Environment

Check session_status.json for

Полный SKILL.md на GitHub

Установить orchestration-test-gen в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

assertion-patterns.mdinfrastructure-dedup.mdmcp-test-execution.mdstored-procedure-wrapping.mdtest-categorization.md

FAQ

Что делает скилл orchestration-test-gen?

Generate AAA orchestration tests (isolated or grouped) for ETL-to-Snowflake elements. Scoped to elements assigned to the current phase in ROADMAP.md. Use when the stabilization skill invokes test generation for an orchestration phase.

Как установить скилл orchestration-test-gen?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл orchestration-test-gen запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить orchestration-test-gen с