djobbo/alambic/wd-test-format
Claude Code and agent skill by djobbo/alambic
- community
Checking that the SKILL.md file is still in the repository.
Detailed guide for authoring .wd-test files in workerd, with examples of bindings, Durable Objects, multi-service configs, TypeScript tests, and network access.
Install
npx vskill@latest install djobbo/alambic/wd-test-formatSKILL.md
The same SKILL.md was published earlier as djobbo/alambic/wd-test-format.
.wd-test File Format
.wd-test files are Cap'n Proto configs that define test workers for workerd's test framework. They use the schema defined in src/workerd/server/workerd.capnp.
MANDATORY: Load Reference File When Relevant
This skill is split across multiple files for context efficiency. The core patterns below cover standard single-service tests. Advanced configuration patterns live in a reference file.
You MUST read the reference file before writing or reviewing test configs that involve its subject matter. Do not guess at advanced config syntax — the reference file contains the exact patterns and fields required. Skipping it WILL lead to incorrect configs that fail at runtime.
| File | MUST load when... | |
|---|---|---|
reference/advanced-configs.md | Test involves Durable Objects, multiple services | |
| communicating via service bindings, outbound network access, | ||
| external services/sockets, or TypeScript source files |
When in doubt about whether the reference file is relevant, load it — the cost of reading is far less than the cost of a broken test config.
Basic Structure
Key rules:
- The const name (e.g.,
unitTests) must match what the test runner expects modulesusesembedto inline file contents at build time- The first module should be named
"worker"— this is the entry point compatibilityFlagscontrol which APIs are available. Use thecompat-date-attool to look up available flags and their enable dates.compatibilityDateshould not be used in wd-test; use specific flags instead
Module Types
Bindings
Bindings make services, data, and namespaces available to the worker via env:
Test JavaScript Structure
Test files export named objects with a test() method:
BUILD.bazel Integration
Additional data entries for fixture files:
Test Variants
Every wd_test() automatically generates three variants:
| Target suffix | Compat date | Description | |
|---|---|---|---|
@ | 2000-01-01 | Default, tests with oldest compat date | |
@all-compat-flags | 2999-12-31 | Tests with all flags enabled | |
@all-autogates | 2000-01-01 | Tests with all autogates enabled |
Run specific variants:
Scaffolding
Use just new-test to scaffold a new test:
This creates the .wd-test file, .js test file, and appends the wd_test() rule to BUILD.bazel.
Security
- Security scanPassed, 90 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryChecking.repos/workerd/.opencode/skills/wd-test-format/SKILL.md
Popularity
- Repository stars
- 1
- 7-day trend score
- 0
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/djobbo/alambic/wd-test-format)