Agent SkillsUsefulSoftwareCo/executor › wrdn-effect-vitest-tests

wrdn-effect-vitest-tests

GitHub

规范仓库内测试代码,强制使用@effect/vitest替代原生vitest导入。禁止在条件分支中使用expect,需拆分测试或显式断言,确保测试确定性与Effect兼容性。

.agents/skills/wrdn-effect-vitest-tests/SKILL.md UsefulSoftwareCo/executor

Trigger Scenarios

lint提示vitest导入问题 测试中存在条件断言

Install

npx skills add UsefulSoftwareCo/executor --skill wrdn-effect-vitest-tests -g -y
More Options

Non-standard path

npx skills add https://github.com/UsefulSoftwareCo/executor/tree/main/.agents/skills/wrdn-effect-vitest-tests -g -y

Use without installing

npx skills use UsefulSoftwareCo/executor@wrdn-effect-vitest-tests

指定 Agent (Claude Code)

npx skills add UsefulSoftwareCo/executor --skill wrdn-effect-vitest-tests -a claude-code -g -y

安装 repo 全部 skill

npx skills add UsefulSoftwareCo/executor --all -g -y

预览 repo 内 skill

npx skills add UsefulSoftwareCo/executor --list

SKILL.md

Frontmatter
{
    "name": "wrdn-effect-vitest-tests",
    "description": "Keep tests deterministic and Effect-aware. Use when lint flags direct vitest imports or conditional assertions inside tests.",
    "allowed-tools": "Read Grep Glob Bash"
}

Use @effect/vitest for tests in this repo.

Fix Shape

  • Import describe, it, expect, and helpers from @effect/vitest.
  • Import utility helpers from @effect/vitest/utils when needed.
  • Do not import from raw vitest except in config or tooling files.
  • Do not put expect(...) behind if, ternary, logical, or switch branches.
  • Split conditional behavior into separate tests, or assert the branch condition and expected value explicitly.

Bad

if (result.ok) {
  expect(result.value).toBe("x");
}

Good

expect(result).toEqual({ ok: true, value: "x" });

Version History

  • fd4fb02 Current 2026-07-05 10:55

Same Skill Collection

.agents/skills/stack/SKILL.md
.agents/skills/wrdn-effect-atom-optimistic/SKILL.md
.agents/skills/wrdn-effect-atom-reactivity-keys/SKILL.md
.agents/skills/wrdn-effect-promise-exit/SKILL.md
.agents/skills/wrdn-effect-raw-fetch-boundary/SKILL.md
.agents/skills/wrdn-effect-schema-boundaries/SKILL.md
.agents/skills/wrdn-effect-schema-inferred-types/SKILL.md
.agents/skills/wrdn-effect-typed-errors/SKILL.md
.agents/skills/wrdn-effect-value-inferred-types/SKILL.md
.agents/skills/wrdn-package-boundaries/SKILL.md
.agents/skills/wrdn-typescript-type-safety/SKILL.md
.claude/skills/emulate/SKILL.md
.claude/skills/prod-telemetry/SKILL.md
.claude/skills/self-contained-modals/SKILL.md
.skills/cli-release/SKILL.md
.skills/effect-atom-optimistic-updates/SKILL.md
.skills/effect-http-testing/SKILL.md
.skills/effect-use-pattern/SKILL.md
.skills/graphite/SKILL.md
.skills/warden-security-review/SKILL.md

Metadata

Files
0
Version
8bc037d
Hash
d3835d20
Indexed
2026-07-05 10:55

Accueil - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-07-17 15:35
浙ICP备14020137号-1 $Carte des visiteurs$