smoke-testing-web-games
Smoke-tests a browser game build in a headless browser through load, idle, and input phases, failing on console errors, uncaught exceptions, or crashes. Use after changes that can reach browser runtime, especially game-loop, input, dependency, entry-point, or build-output changes. Skip changes the running build cannot reach. This checks runtime health, not gameplay quality, balance, visuals, or mechanic correctness. Requires Node 18+ and Playwright with Chromium in the target project.
How do I install this agent skill?
npx skills add https://github.com/abagames/agentic-gamedev-skills --skill smoke-testing-web-gamesIs this agent skill safe to install?
- Gen Agent Trust Hubpass
The skill is a testing utility that uses Playwright to perform automated smoke tests on web games. It dynamically resolves its main dependency from the target project and executes arbitrary web content in a headless browser, which introduces a surface for indirect prompt injection via captured error messages or console logs.
- Socketpass
No alerts
- Snykpass
Risk: LOW · No issues
What does this agent skill do?
Smoke-Testing Web Games
Run this real-browser gate once per completed change unit that can reach the game runtime. It catches environment and input-handler failures that mocks or idle-only tests can miss.
Requirements and Usage
- Node 18+ and Playwright with Chromium installed in the project under test. The script resolves
playwrightfrom the directory where it runs. - Network access when the page loads CDN resources; failed loads surface as console errors.
- Run from the game project directory:
node <skill-dir>/scripts/smoke-test.mjs path/to/index.html # 3s idle, 6s input
node <skill-dir>/scripts/smoke-test.mjs http://localhost:5173 --idle 5 --input 10
Serve over HTTP when the game uses ES modules, fetch, or other origin-restricted features.
The harness runs these phases in order:
- load — navigate through the
loadevent; navigation failure is immediate failure. - idle — wait untouched for startup and frame-loop errors.
- input — send scattered pointer taps, Space and arrow-key taps, plus a short arrow-key hold, with pauses for timers and spawns.
It prints each error with its phase. Exit 0 means PASS, 1 means a runtime error or load failure, and 2 means a harness problem such as missing Playwright or bad arguments.
Boundaries
- A PASS means only that the page loaded and survived the exercised idle/input paths without reported errors. It does not prove that the loop started or that mechanics, audio, visuals, performance, difficulty, or balance are correct.
- For state transitions or scoring formulas, use
probing-web-game-mechanics; test silent no-op behavior with a dedicated runtime check. - The generic input schedule does not cover custom keys. Extend it or report those controls as untested.
- Treat CDN/network errors as failures, but rerun before attributing a flaky external load to game code.
Harness Self-Test
node scripts/smoke-test.mjs assets/fixtures/fixture-ok.html # PASS, exit 0
node scripts/smoke-test.mjs assets/fixtures/fixture-input-crash.html # FAIL, exit 1
node scripts/smoke-test.mjs assets/fixtures/fixture-input-crash.html --input 0 # PASS: idle misses the bug
How can the creator link this skill?
Add the canonical catalog link to the repository README so users can inspect current installs and available audits. The publishing guide covers the complete discovery path.
<a href="https://skillzs.dev/skills/abagames/agentic-gamedev-skills/smoke-testing-web-games">View smoke-testing-web-games on skillZs</a>