OpenEnv: Skill for Claude Code

.claude/skills/write-tests/SKILL.md

write-tests is a skill for Claude Code from huggingface/OpenEnv. It costs 17 tokens per session (487 once invoked), scanned A, original, BSD-3-Clause.

A workflow for writing failing tests from software requirements. It reads existing test patterns, adds tests for the acceptance criteria, and confirms they fail before implementation begins.

In plain words
What is it for?
Use it before implementation to encode requirements, test edge cases, create test files, and verify that the new tests fail as expected.
Why use it?
Starting with failing tests makes the intended behavior explicit and confirms that the tests can detect the missing implementation.

Skill for Claude Code ✓ vendor

Written for Claude Code: context: fork in frontmatter. Also seen: agent in frontmatter.

This is huggingface/OpenEnv's own configuration. It tells Claude Code how to work on OpenEnv itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything OpenEnv configures →

About the project

OpenEnv is a framework for creating, deploying, and using isolated execution environments through simple APIs modeled on Gymnasium. It is intended for researchers and developers training agents with reinforcement learning, as well as creators who need secure environments that can be deployed and accessed through familiar protocols. The catalogue add-ons provide agent integrations and workflows for using OpenEnv.

huggingface/OpenEnv · 2,739 stars · on GitHub · huggingface.co

Reuse

Borrowing it

Nothing to install: this file belongs to huggingface/OpenEnv. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/huggingface/OpenEnv/main/.claude/skills/write-tests/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/huggingface/OpenEnv

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for write-tests

README.md
[![agentmods](https://agentmods.dev/badge/skills/huggingface/openenv/write-tests/github.svg)](https://agentmods.dev/skills/huggingface/openenv/write-tests)
Your own site
<a href="https://agentmods.dev/skills/huggingface/openenv/write-tests"><img src="https://agentmods.dev/badge/skills/huggingface/openenv/write-tests/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for write-tests

Your own site · 80×15
<a href="https://agentmods.dev/skills/huggingface/openenv/write-tests"><img src="https://agentmods.dev/badge/skills/huggingface/openenv/write-tests.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 17 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 487 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00017 $0.00487
Opus 5.5 $0.00007 $0.00195
Sonnet 5.5 $0.00003 $0.00097
Haiku 4.5 $0.00002 $0.00049

Measured 1mo ago against content hash e5904765dff7, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

write-tests scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/skills/write-tests/SKILL.md · 86 lines

How it starts

The opening of the file, as written. The whole thing — 86 lines — stays where its author put it; the contents beside it link to each section on GitHub.

/write-tests

Write failing tests that encode acceptance criteria.

Usage

/write-tests
/write-tests Add logout button to header

When to Use

  • After creating a todo that requires implementation
  • Before running /implement
  • When you have clear acceptance criteria

When NOT to Use

  • Implementation already exists (tests would pass immediately)
  • You're exploring or prototyping (not TDD mode)
  • Just adding to existing test coverage

What It Does

  1. Analyzes the current todo/requirement
  2. Reads existing tests to understand patterns
  3. Writes test files that verify acceptance criteria
  4. Verifies tests FAIL (proves they test something real)
  5. Returns test file paths for /implement

Output

The tester agent will produce:

## Tests Written

### Files Created/Modified
- `tests/test_client.py`

### Tests Added
| Test | Verifies |
|------|----------|
| `test_client_reset_returns_observation` | Reset returns valid observation |
| `test_client_step_advances_state` | Step mutates state correctly |
| `test_client_handles_invalid_action` | Error handling for bad input |

### Verification
All tests FAIL as expected (no implementation yet).

### Next Step
Run `/implement` to make these tests pass.

Rules

  1. Read existing tests first to understand patterns and conventions
  2. Test behavior, not implementation - write from user's perspective
  3. Integration tests first, then unit tests if needed
  4. Each test verifies ONE thing clearly
  5. Run tests to verify they fail before returning

Anti-patterns (NEVER do these)

  • Writing tests that pass without implementation
  • Testing implementation details instead of behavior
  • Writing overly complex test setups
  • Adding implementation code (that's /implement's job)
  • Writing tests that duplicate existing coverage

Completion Criteria

Before returning, verify:

  1. Tests compile/run successfully (pytest can collect them)
  2. Tests FAIL (no implementation yet)
  3. Test names clearly describe what they verify
  4. Tests follow existing project patterns (see tests/ for examples)

Read the full file on GitHub · 86 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 86 lines · 17 tokens per session scan A e5904765dff7

Subscribe to this mod's changes

write-tests is a skill published in the GitHub repository huggingface/OpenEnv (2,739 stars, last pushed 8d ago), licensed BSD-3-Clause. It adds 17 tokens to every session and 487 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.