rstest-debugging — скилл для Claude Code: установка
Скилл rstest-debugging помогает найти причину проблем Rstest со стартом, сборкой, рантаймом, логами, памятью и производительностью по трассам и сопоставимым замерам.
MIT 133 установок ★ 100 обновлён 2026-10-22
npx skills add rstackjs/agent-skills --skill rstest-debugging -a claude-codeЧто делает rstest-debugging
Скилл сначала задаёт сопоставимые базовые замеры для одного файла и полного набора тестов. Затем предлагает запустить rstest --trace и определить, где возникает стоимость: при сборке и старте, загрузке и сборе тестов, выполнении тестов и хуков или работе CLI, отчёта и завершения.
Для уточнения причины используются DEBUG=rstest, профилировщик и Rsdoctor, но только после сужения области поиска. В справочных файлах разобраны зависимости и bundling, граф сборки замоканных модулей, вывод, пулы, изоляция и память. Сравнение bundleDependencies: false и bundleDependencies: true выполняется отдельно, потому что ни один вариант не объявлен универсально быстрым.
Скилл советует менять одну переменную за раз и сохранять изменение только при повторяемом результате без нарушения поведения, обнаружения тестов, снапшотов и покрытия. Финальные выводы нужно делать на установленной в проекте версии Rstest, а локальные или ещё не выпущенные результаты помечать отдельно.
Какие задачи решает
- найти этап жизненного цикла Rstest, который тормозит тесты
- сравнить запуск одного файла и полного набора
- проверить влияние
bundleDependenciesна загрузку зависимостей - разобраться, почему замоканный модуль попадает в граф сборки
- отделить расход памяти, вывод и настройки пулов
Примеры запросов агенту
- Разбери медленный запуск Rstest: сравни один файл и полный набор, затем используй
rstest --trace. - Проверь, влияет ли
bundleDependenciesна проблему с загрузкой зависимостей, меняя только один параметр за раз. - Найди причину большого расхода памяти в тестах и проверь вывод, пулы и изоляцию без изменения покрытия.
Как установить rstest-debugging
1Через Skills CLI (Vercel)
npx skills add rstackjs/agent-skills --skill rstest-debugging -a claude-code2Вручную: положить файлы
~/.claude/skills/rstest-debugging/SKILL.mdПапка скилла целиком; для одного проекта — .claude/skills/rstest-debugging/
1Через Skills CLI (Vercel)
npx skills add rstackjs/agent-skills --skill rstest-debugging -a codex2Вручную: положить файлы
.agents/skills/rstest-debugging/SKILL.mdДля всех проектов — ~/.agents/skills/
1Через Skills CLI (Vercel)
npx skills add rstackjs/agent-skills --skill rstest-debugging -a cursor2Вручную: положить файлы
.cursor/skills/rstest-debugging/SKILL.mdCursor читает и .agents/skills/, и .claude/skills/
1GitHub CLI
gh skill install rstackjs/agent-skills skills/rstest-debugging2Вручную: положить файлы
.github/skills/rstest-debugging/SKILL.md1Через Skills CLI (Vercel)
npx skills add rstackjs/agent-skills --skill rstest-debugging -a gemini-cli2Командой платформы
gemini skills install https://github.com/rstackjs/agent-skills --path skills/rstest-debuggingВручную: положить файлы
.devin/skills/rstest-debugging/SKILL.mdСтарый путь .windsurf/skills/ тоже читается
Через Skills CLI (Vercel)
npx skills add rstackjs/agent-skills --skill rstest-debugging -a opencodeClaude.ai
Упакуйте папку в zip и загрузите в Settings → Capabilities → Skills
По шагам, с командами для каждой платформы: Как установить скилл в Claude Code: пять способов
Вопросы о rstest-debugging
Как установить rstest-debugging в Claude Code?
Выполните npx skills add rstackjs/agent-skills --skill rstest-debugging -a claude-code, затем проверьте файл ~/.claude/skills/rstest-debugging/SKILL.md.
Что делает rstest-debugging?
Скилл ведёт диагностику проблем Rstest со стартом, сборкой, рантаймом, логами, памятью и производительностью. Он опирается на трассы, базовые замеры и сравнение одного изменения за раз.
Какие версии Rstest учитываются для per-test bundle coverage?
Экспериментальная per-test bundle coverage рассматривается для Rstest 0.11.7 и новее. Для финальных выводов используется установленная в проекте версия Rstest.
Исходный текст
SKILL.md · MIT
--- name: rstest-debugging description: Diagnose Rstest startup, build, runtime, logging, memory, or performance problems using traces and comparable measurements. --- # Rstest debugging Diagnose the measured lifecycle stage before changing configuration. Keep behavior and the test manifest fixed, change one variable at a time, and remove experiments that do not produce a repeatable benefit. ## Workflow 1. Establish comparable single-file and full-scope baselines with `references/performance-measurement.md`. 2. Run `rstest --trace` when supported and classify the cost as host build/startup, runtime load/setup/collect, test bodies/hooks, or CLI/report/teardown overhead. 3. Use `DEBUG=rstest` for resolved config and build output. For Rstest 0.11.7+ experimental per-test bundle coverage, follow `references/performance-measurement.md`. Use Rsdoctor only after evidence points to the compiler. Use verbose reporting or a profiler only after narrowing to runtime files/cases. 4. If dependency loading or compilation is implicated, read `references/dependency-bundling.md`. Compare the environment default, `bundleDependencies: false`, and `bundleDependencies: true`; neither bundling nor externalization is universally faster. 5. If a fully mocked heavy module still reaches the build graph, read `references/mocked-module-build-graph.md` before testing an exact external. 6. If assets, console output, pools, isolation, or memory dominate, read `references/runtime-output-memory.md`. 7. Rerun the representative file and full scope. Keep a change only when behavior, discovery, snapshots, and coverage remain valid and the benefit survives repeated measurement. Remove traces, profiles, and `.rstest` debug artifacts created by the diagnosis before handing off. ## Guardrails - Use the project's installed Rstest for final claims. Label local checkout or unreleased diagnostic results separately. - Keep Node version, test files, coverage, cache state, environment, workers, and command shape fixed while comparing. - Do not add worker durations that overlap or subtract runner/build/tests values without verifying their lifecycle boundaries. - Do not treat aggregate process-tree RSS as physical memory; it can double-count shared pages. - Do not disable isolation, reduce coverage, silence failures, or change production/test semantics for a benchmark win. - Do not stack speculative aliases, externals, compiler hooks, pool settings, or caches. Preserve only the measured minimum. ## Handoff from migration When invoked from `migrate-to-rstest`, first confirm that the Jest/Vitest and Rstest manifests match. If the migration intentionally adds tests, report same-scope performance separately from final expanded-scope performance.
© rstackjs · MIT · rstackjs/agent-skills