CtrlK
BlogDocsLog inGet started
Tessl Logo
SkillPublic

snapshot-test-refactorer

This guide recommends targeted assertions, partial or inline snapshots, and serializers to make tests clearer and less brittle. It also provides refactoring and maintenance processes, examples, and guidance on when snapshots or visual regression tests are appropriate.

Quality

78%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide
SecuritybySnyk

Passed

No findings from the security scan

Fix and improve this skill with Tessl

tessl review fix ./.agents/skills/snapshot-test-refactorer/SKILL.md
SKILL.md
Quality
Evals
Security

Quality

Scored by GLM 5.3

Content

65%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.

The content is highly actionable — executable, example-driven guidance that covers component tests, data snapshots, serializers, trimming, and visual regression. Its weaknesses are structural: three redundant summary sections, a refactoring workflow missing an explicit "verify tests pass" checkpoint for a batch operation, and a fully inlined layout with a referenced script path that does not exist in the bundle.

Suggestions

Add an explicit verification step to the Refactoring Process (e.g., "Run the test suite and confirm all refactored tests pass before deleting the old snapshot file"), since rewriting snapshot tests is a batch operation and the current workflow ends at 'Delete snapshot'.

Consolidate the overlapping 'Best Practices', 'Output Checklist', and 'Refactoring Checklist' sections into a single checklist to remove restated guidance.

Move the maintenance guidelines and the conversion script into actual reference files (e.g., scripts/convert-snapshots.ts, references/maintenance.md) and link to them, or remove the 'scripts/convert-snapshots.ts' path label if no such file ships with the skill.

DimensionReasoningScore

Conciseness

The body is code-forward with almost no explanation of concepts Claude already knows, but it could be tightened: "Best Practices" (7 items), "Output Checklist" (8 items), and the "Refactoring Checklist" substantially restate points already demonstrated in earlier sections. Fits anchor 3 (mostly efficient, some unnecessary duplication); not 4 because three overlapping summary sections exceed "minor instances that could be trimmed".

3 / 5

Actionability

Nearly every section gives complete, copy-paste-ready TypeScript covering the common cases: component assertions with getByRole/getByText, toMatchInlineSnapshot, toMatchObject partial matching, a snapshot serializer, Playwright visual regression, and a full before/after example. Not below 5: the only weak spot is the "Automated Conversion Script", which is a supplementary stub, and the core examples cover the common cases.

5 / 5

Workflow Clarity

The "Refactoring Process" steps ("1. Run snapshot test, let it fail ... 5. Delete snapshot") give a clear sequence but include no verification that refactored tests actually pass — and since this is a batch/destructive operation rewriting test files, the rubric caps workflow clarity at 3. The maintenance "Review Process" does include verification ("Review EVERY changed snapshot"), which keeps this from scoring lower.

3 / 5

Progressive Disclosure

The single ~375-line file is well-sectioned but monolithic: content that plausibly belongs in separate references (maintenance guidelines, the refactoring checklist, the conversion script) is all inline, and the body labels code as "scripts/convert-snapshots.ts" even though no scripts/ bundle directory exists — a dangling path. Fits anchor 3 (some structure, content that should be separate is inline); not 4 because no reference files exist at all for a skill this size.

3 / 5

Total

14

/

20

Passed

Description

83%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 description in third-person voice with concrete capabilities and an explicit "Use for" trigger clause. Both "what" and "when" are clearly answered, and the niche is well-differentiated. Only minor improvements possible: add a few more natural trigger synonyms and reflect the visual-regression/serializer strategies in the capability list.

DimensionReasoningScore

Specificity

"Refactors brittle snapshot tests into resilient, focused assertions" and "reducing snapshot size, extracting meaningful assertions, and maintaining snapshots" list several concrete actions. Not a 5: coverage has minor gaps — significant parts of the skill (when snapshots are acceptable, visual regression, serializers) are not represented in the description.

4 / 5

Completeness

The "what" is explicit ("Refactors brittle snapshot tests into resilient, focused assertions... maintaining snapshots") and the "when" is explicit with concrete trigger phrases ("Use for 'snapshot testing', 'snapshot refactoring', 'brittle tests', or 'assertion improvement'"). Clearly matches the anchor 5 example structure; not below since neither half is vague or implicit.

5 / 5

Trigger Term Quality

"snapshot testing", "snapshot refactoring", "brittle tests", "assertion improvement" are natural phrases a user would say. Not a 5: common variations like "jest snapshots", "flaky tests", "update snapshots", or tool-specific terms are missing, and "assertion improvement" is slightly stilted.

4 / 5

Distinctiveness Conflict Risk

Snapshot-test refactoring is a clear niche with distinct triggers, so conflict risk is low. Not a 5: "assertion improvement" and "brittle tests" could plausibly also trigger a general testing-best-practices skill, giving minor overlap risk with closely related skills.

4 / 5

Total

17

/

20

Passed

Validation

93%

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

Validation — 15 / 16 Passed

Validation for skill structure

CriteriaDescriptionResult

referenced_paths_exist

Referenced path issues: 1 possibly missing (scripts/convert-snapshots.ts)

Warning

Total

15

/

16

Passed

Repository

sathishssj3/Stereix-Engine

Path

.agents/skills/snapshot-test-refactorer/SKILL.md

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.