CtrlK
BlogDocsLog inGet started
Tessl Logo

writing-tests

Gates whether a new test should exist and forces it to be efficient, protecting CI from low-value test bloat. Use before any change to what a pytest, Jest, or Playwright test asserts or sets up, down to one fixture or one assertion added to an existing block. Front-loads the value bar (every test must catch a realistic regression no existing test already catches; extend the nearest existing test before writing a new standalone one; test behavior through the public interface, not implementation details; collapse near-duplicates into parameterized cases) and the efficiency bar (deterministic, isolated, fast; pick the cheapest test level; Django TestCase over TransactionTestCase; no sleeps, no real network; no time bombs from absolute dates left to age against the real clock; no database a test never uses). Includes a "don't write it" decision tree. For fixing an existing flaky test use `/fixing-flaky-tests`; after this gate says a Playwright test is warranted, use `/playwright-test` for mechanics.

63

Quality

76%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide

SecuritybySnyk

—

The risk profile of this skill

Fix and improve this skill with Tessl

tessl review fix ./.agents/skills/writing-tests/SKILL.md
SKILL.md
Quality
Evals
Security

Quality

Content

63%Weight 40%Scale 1-5

Reviews the quality of instructions and guidance provided to agents. Good implementation is clear, handles edge cases, and produces reliable results.

A rich, opinionated, project-specific testing gate with strong actionable examples and a clear decision sequence. Its main weaknesses are verbosity in several expository passages and progressive-disclosure gaps where heavy detail is inlined and referenced bundle files are missing.

Suggestions

Tighten the discursive prose in the 'Always — determinism and isolation' section into crisper bullets — keep the project-specific facts but cut the narrative padding around clocks and mtimes.

Move the DRF input-validation deep-dive and the determinism/isolation rules into reference files under references/ (which the body already cites) so SKILL.md stays a lean overview with one-level-deep pointers.

Add the referenced files (references/mistakes-we-make.md, references/database-free-test-classes.md) to the bundle so the signaled links resolve, or remove the links if the files are not bundled.

DimensionReasoningScore

Conciseness

Most of the content is genuinely project-specific guidance that earns its place, but several passages are discursively padded — e.g. the delta-rs mtime explanation and the wall-clock-budget narrative — that could be tightened into crisper bullets without losing clarity.

3 / 5

Actionability

It gives concrete, executable guidance — a copy-paste SimpleTestCase serializer example, an exact grep TTL command, specific helper paths (posthog/test/persons.py) and library calls (time_machine.travel with tick=False, jest.useFakeTimers) — with only minor gaps where guidance stays at the principle level.

4 / 5

Workflow Clarity

The gate is a clearly sequenced decision procedure — two questions, the five no's, pyramid weighting, then the PR justification checkpoint ('If you can't write that line, you've found a test that shouldn't be in the PR') — with most checkpoints present, though it lacks explicit error-recovery feedback loops.

4 / 5

Progressive Disclosure

Section structure and markdown reference links are clearly signaled, but the body inlines substantial reference-grade detail (the entire 'Always — determinism and isolation' section, the DRF validation deep-dive) and the referenced files references/mistakes-we-make.md and references/database-free-test-classes.md are not present in the bundle, so the signaled references do not resolve.

3 / 5

Total

14

/

20

Passed

Description

88%Weight 40%Scale 1-5

Based on the skill's description, can an agent find and select it at the right time? Clear, specific descriptions lead to better discovery.

A strong, concrete description that clearly states both what the skill does and when to use it, with explicit routing to sibling skills. It is somewhat verbose for a description field and could enumerate a few more natural trigger synonyms, but it is comprehensive and specific.

DimensionReasoningScore

Specificity

The description lists multiple concrete, specific actions across both bars — 'extend the nearest existing test before writing a new standalone one', 'collapse near-duplicates into parameterized cases', 'Django TestCase over TransactionTestCase', 'no sleeps, no real network', 'no time bombs from absolute dates' — giving comprehensive coverage of the skill's behavior.

5 / 5

Completeness

It explicitly answers both what ('Gates whether a new test should exist and forces it to be efficient...') and when ('Use before any change to what a pytest, Jest, or Playwright test asserts or sets up, down to one fixture or one assertion') with concrete trigger phrases.

5 / 5

Trigger Term Quality

It names the natural framework triggers a user would say ('pytest, Jest, or Playwright test', 'fixture', 'assertion') but omits common synonyms like 'unit test', 'integration test', or 'spec' that would round out coverage to a 5.

4 / 5

Distinctiveness Conflict Risk

The skill has a clear niche — gating new-test creation — and explicitly routes sibling concerns to '/fixing-flaky-tests' and '/playwright-test', but it still operates in a testing domain with closely related skills, leaving minor overlap risk.

4 / 5

Total

18

/

20

Passed

Validation

87%

Checks the skill against the spec for correct structure and formatting. All validation checks must pass before discovery and implementation can be scored.

Validation — 14 / 16 Passed

Validation for skill structure

CriteriaDescriptionResult

relative_links

Relative link issues: 3 missing, 2 suspicious

Warning

referenced_paths_exist

Referenced path issues: 5 missing

Warning

Total

14

/

16

Passed

Repository
PostHog/posthog
Reviewed

Table of Contents

Is this your skill?

If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.