agentleFS
MRCalderon3DMRCalderon3D/everything-game-dev-code/skills/web/web-testing/SKILL.md

web-testing

Skill90 starsChanged 8 months agoMITView on GitHub

Test browser games with fast unit tests for pure logic, headless smoke tests, and a deliberate browser matrix.

5 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

7 rules. 0 are common, 7 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 4 edited versions we read keep these.

  • 7

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Test browser games with fast unit tests for pure logic, headless smoke tests, and a deliberate browser matrix.

    line 11
  2. Distinctive:

    keep game rules, scoring, collision math, and save serialization in pure modules with no browser globals, and cover them with fast unit …

    line 25
  3. Distinctive:

    write scenario tests that step the simulation through real sequences (spawn, collide, score, die) and assert end state, not implementation …

    line 27
  4. Distinctive:

    add a headless browser smoke test that loads the built game, waits for boot, and fails on console errors, missing assets, or a blank canvas

    line 28
  5. Distinctive:

    run a manual matrix pass before release across the main desktop engines and at least one real touch device, checking input, audio unlock, …

    line 29
  6. Distinctive:

    test strategy split by layer (unit, deterministic scenario, headless smoke, manual matrix)

    line 32
  7. Distinctive:

    Keep this skill aligned with the relevant rules layer and current project documentation.

    line 62

“Common” is measured: kept by at least 6 in 10 of the 4 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Web Testing

Purpose

Test browser games with fast unit tests for pure logic, headless smoke tests, and a deliberate browser matrix.

Use When

  • adding tests to a browser game or deciding what to cover
  • regressions keep appearing in game rules, scoring, or save data
  • a release needs confidence across browsers and devices

Inputs

  • feature risk profile (what breaks the game versus what annoys)
  • separation between pure logic and browser-bound code
  • available runners (node-based unit runner, headless browser tool)
  • target browser and device list

Process

  1. keep game rules, scoring, collision math, and save serialization in pure modules with no browser globals, and cover them with fast unit tests
  2. make simulation deterministic for tests: seedable random, fixed timestep, and a step function that can be advanced N ticks without rendering
  3. write scenario tests that step the simulation through real sequences (spawn, collide, score, die) and assert end state, not implementation details
  4. add a headless browser smoke test that loads the built game, waits for boot, and fails on console errors, missing assets, or a blank canvas
  5. run a manual matrix pass before release across the main desktop engines and at least one real touch device, checking input, audio unlock, resize, and save persistence

Outputs

  • test strategy split by layer (unit, deterministic scenario, headless smoke, manual matrix)
  • candidate test cases per layer
  • determinism requirements for the simulation
  • browser and device matrix with pass criteria

Quality Bar

  • unit tests run in milliseconds with no DOM, canvas, or network dependencies
  • the same seed and tick count always produce the same simulation state, so failures reproduce exactly
  • the smoke test exercises the production build and catches load-order, path, and boot regressions that unit tests cannot see
  • gating tests are separated from exploratory checks; the release blocks only on the former
  • the matrix includes a genuinely different browser engine and a real touch device, not just one desktop browser at several window sizes

Common Failure Modes

  • logic welded to rendering or input so nothing can be tested without spinning up a browser
  • unseeded randomness and wall-clock time making every scenario test flaky
  • asserting internal fields and call counts instead of observable game state, so refactors break green tests
  • a smoke test against the dev server while the deployed build fails on base paths or asset casing
  • declaring browser support from a single-engine test pass and missing audio, fullscreen, or touch differences elsewhere

Related Agents

  • qa-lead
  • gameplay-programmer
  • web-reviewer

Related Commands

  • tdd
  • verify
  • qa-plan

Notes

  • Keep this skill aligned with the relevant rules layer and current project documentation.
  • Framework scenes are integration territory; keep their logic thin and push decisions into pure modules where the cheap tests live.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.