Index of every page on this site: llms.txt
All skills
Run it yourself

Writes automated tests that hunt for errors - edge cases above all, plus logic, structure, state, error-handling and permission errors - and proves each test by making it fail. After feature code it writes the tests and breaks the guarded code to see each one go red; for a bug it writes the reproduction test first and watches it fail before the fix. Covers choosing unit, integration or end-to-end, test doubles, test data, browser tests and flaky tests. Use when writing or fixing tests, adding coverage for a change, after implementing a feature, when fixing a bug, when a test is flaky or a UI test broke, or when the user asks "what could break here" or to check edge cases. Not for listing manual test cases - use test-cases; not for proving a change in the real app against an answer key - use prove; not for reviewing a diff - use `review`; not for finding why something fails - use debug; Go specifics live in the go skill.

  • 6 files
  • 28.9 KB
  • Updated 3 weeks ago
  • GitHub
Use this Skill: https://skilld.dev/gh/avik-creator/agent-skills/testing

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

referencesflaky.md

≈485 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Flaky and newly red tests

Read when a test passes and fails on the same code, or a UI test turned red.

Is it flaky?

Flaky means different results on the same commit. One red run after a change is a failure until shown otherwise. Why: calling a real regression "flaky" hides it.

Reproduce before fixing

Run it many times until it fails at least once, then run it the same way after the fix and expect no failures:

  • Playwright: --repeat-each=<n>, with more workers to add pressure.
  • Go: go test -run <name> -count=<n> -race.
  • Other runners: a loop in the shell. Pick the count with the user; say what you ran. Without a failing reproduction you can't tell a fix from luck.

Find the cause, in this order

  1. Passes alone, fails in the suite: shared state or order. Look for data another test leaves, a shared account, a global, a fixed id.
  2. Fails more in CI: timing or environment. Look for a missing wait on an async step, CPU contention, a different time zone, locale or image.
  3. Fails at certain times: dates. Look for "now", midnight, month end, DST. Freeze the clock.
  4. Makes an external call: that service. Stub it at the HTTP boundary.
  5. Otherwise: an async step nobody waits for. Wait on the result the user sees.

A UI test that turned red

Find out why before editing the test. A locator timeout can be an app regression, a login or network problem, or a page that isn't ready. Read the trace first. After fixing a locator, run the whole affected file, because the new locator may match the wrong element. Confirm a feature was really removed before deleting its tests.

Not fixes

  • A retry, a sleep, or a longer timeout. Each one hides the race. If the config retries, run with --fail-on-flaky-tests (Playwright) so a pass after a retry still fails.
  • Skipping the test. A skip is flagged by ship's bar-guard; it needs the user's yes, a reason in the code, and an issue link.

Source: SKILL.md on GitHub

No rule matched.

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No third-party reports yet.

Signed by skilld at a0324a3. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 4 days ago.

Activeupdated 3 weeks ago

README badge

README badge for avik-creator/agent-skills/testing