Web Application Testing

VerifiedCaution

Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing screenshots, and viewing browser logs.

Sby Skills Guide Bot
TestingIntermediate
7/22/2026
Claude CodeCursorCodex
#playwright#browser-automation#e2e-testing#web-testing#python

Recommended for

Automated summary

This skill provides a Python Playwright toolkit for driving and testing local web applications, including a helper script that manages the lifecycle of dev servers.

Strengths

  • A `with_server.py` helper that starts and stops one or more servers before running the Playwright script, removing manual process handling
  • A clear decision tree separating static HTML from dynamic apps, plus a reconnaissance-then-action workflow
  • Explicit callout of the common pitfall: waiting for `networkidle` before inspecting a dynamic app's DOM
  • Bundled scripts meant to be used as black boxes via `--help`, keeping the context window clean

Limitations

  • Limited to Playwright in Python; no guidance for other languages or for Cypress
  • Assumes Python and Playwright are already installed, without covering setup
  • Does not address visual regression diffing, parallel runs, or CI integration
When to use it

Use it when you need to verify or debug the behavior of a local web app by driving a real browser and capturing screenshots or logs.

When not to use it

Skip it if you need a unit test suite or a full continuous integration setup, since the skill focuses on ad hoc Playwright automation.

Security analysis

Caution
Quality score86/100

The skill is designed for legitimate local web-app testing with Playwright and does not include destructive, exfiltrating, or obfuscated instructions. However, it directs execution of shell commands, manages local servers, and discourages source inspection of bundled scripts, so it carries meaningful execution risk and should be used only with trusted bundled files.

Findings
  • •Instructs agent to execute local server commands and Playwright automation scripts via bash, which is powerful but appropriate for local web testing.
  • •Advises treating bundled scripts as black boxes and not reading their source unless necessary, reducing auditability if the scripts are not trusted.
  • •The with_server.py helper accepts arbitrary shell commands for --server, which could be abused if command arguments come from untrusted input.
How this analysis is made

Examples

Vérifier le flux de connexion
Start my Vite dev server on port 5173 and use Playwright to log in with test@example.com / password123, then screenshot the dashboard.
Déboguer un bouton inactif
My React app on localhost:3000 has a submit button that does nothing. Run it with Playwright, capture console logs, and tell me what's failing.
Inspecter le DOM rendu
Navigate to http://localhost:8000, wait for networkidle, and list all buttons and input selectors on the page so I can write tests against them.

name: webapp-testing description: Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing browser screenshots, and viewing browser logs. license: Complete terms in LICENSE.txt

Web Application Testing

To test local web applications, write native Python Playwright scripts.

Helper Scripts Available:

  • scripts/with_server.py - Manages server lifecycle (supports multiple servers)

Always run scripts with --help first to see usage. DO NOT read the source until you try running the script first and find that a customized solution is abslutely necessary. These scripts can be very large and thus pollute your context window. They exist to be called directly as black-box scripts rather than ingested into your context window.

Decision Tree: Choosing Your Approach

User task → Is it static HTML?
    ├─ Yes → Read HTML file directly to identify selectors
    │         ├─ Success → Write Playwright script using selectors
    │         └─ Fails/Incomplete → Treat as dynamic (below)
    │
    └─ No (dynamic webapp) → Is the server already running?
        ├─ No → Run: python scripts/with_server.py --help
        │        Then use the helper + write simplified Playwright script
        │
        └─ Yes → Reconnaissance-then-action:
            1. Navigate and wait for networkidle
            2. Take screenshot or inspect DOM
            3. Identify selectors from rendered state
            4. Execute actions with discovered selectors

Example: Using with_server.py

To start a server, run --help first, then use the helper:

Single server:

python scripts/with_server.py --server "npm run dev" --port 5173 -- python your_automation.py

Multiple servers (e.g., backend + frontend):

python scripts/with_server.py \
  --server "cd backend && python server.py" --port 3000 \
  --server "cd frontend && npm run dev" --port 5173 \
  -- python your_automation.py

To create an automation script, include only Playwright logic (servers are managed automatically):

from playwright.sync_api import sync_playwright

with sync_playwright() as p:
    browser = p.chromium.launch(headless=True) # Always launch chromium in headless mode
    page = browser.new_page()
    page.goto('http://localhost:5173') # Server already running and ready
    page.wait_for_load_state('networkidle') # CRITICAL: Wait for JS to execute
    # ... your automation logic
    browser.close()

Reconnaissance-Then-Action Pattern

  1. Inspect rendered DOM:

    page.screenshot(path='/tmp/inspect.png', full_page=True)
    content = page.content()
    page.locator('button').all()
    
  2. Identify selectors from inspection results

  3. Execute actions using discovered selectors

Common Pitfall

❌ Don't inspect the DOM before waiting for networkidle on dynamic apps ✅ Do wait for page.wait_for_load_state('networkidle') before inspection

Best Practices

  • Use bundled scripts as black boxes - To accomplish a task, consider whether one of the scripts available in scripts/ can help. These scripts handle common, complex workflows reliably without cluttering the context window. Use --help to see usage, then invoke directly.
  • Use sync_playwright() for synchronous scripts
  • Always close the browser when done
  • Use descriptive selectors: text=, role=, CSS selectors, or IDs
  • Add appropriate waits: page.wait_for_selector() or page.wait_for_timeout()

Reference Files

  • examples/ - Examples showing common patterns:
    • element_discovery.py - Discovering buttons, links, and inputs on a page
    • static_html_automation.py - Using file:// URLs for local HTML
    • console_logging.py - Capturing console logs during automation

From the file to a first result

The download contains exactly the content displayed on this page. This copy may differ from the latest version in the source repository.

View the source and supporting files

This download contains SKILL.md only. Any scripts, references, templates and dependencies are not included. Get the required files from the source, preserving their directory structure, before continuing.

1. Download the file

Download SKILL.md

From the root of a test project, save the file as .skill-downloads/web-application-testing-mrwakgh4/SKILL.md, or use the command below. This folder is for inspecting the skill before installation.

Command for macOS/Linux or WSL: requires a POSIX shell and curl. On Windows without WSL, use the download button and create the folder manually.

mkdir -p '.skill-downloads/web-application-testing-mrwakgh4' && curl --fail --show-error --location 'https://skills-guides.com/api/skills/web-application-testing-mrwakgh4/download' --output '.skill-downloads/web-application-testing-mrwakgh4/SKILL.md.part' && mv '.skill-downloads/web-application-testing-mrwakgh4/SKILL.md.part' '.skill-downloads/web-application-testing-mrwakgh4/SKILL.md'

2. Check prerequisites

Read SKILL.md before using it. If it references scripts or external services, inspect them and prepare the required access in your test environment.

No recognized prerequisites section in this file. This does not mean it is self-contained: libraries, tools and access requirements may be mentioned elsewhere in the content or source repository.

The platforms on this page are catalog indications. The paths below follow tool documentation; they do not prove this skill has been run in those tools. No minimum tool version is confirmed for this listing.

3. Load the skill

After inspection, copy the complete folder into your project using one of the commands below, then open a new tool session. The command stops if a folder with the same name already exists: compare the files before replacing it.

Claude Code
test -f '.skill-downloads/web-application-testing-mrwakgh4/SKILL.md' && test -s '.skill-downloads/web-application-testing-mrwakgh4/SKILL.md' && mkdir -p '.claude/skills' && test ! -e '.claude/skills/webapp-testing' && cp -R '.skill-downloads/web-application-testing-mrwakgh4' '.claude/skills/webapp-testing'

Cursor
test -f '.skill-downloads/web-application-testing-mrwakgh4/SKILL.md' && test -s '.skill-downloads/web-application-testing-mrwakgh4/SKILL.md' && mkdir -p '.cursor/skills' && test ! -e '.cursor/skills/webapp-testing' && cp -R '.skill-downloads/web-application-testing-mrwakgh4' '.cursor/skills/webapp-testing'

Codex
test -f '.skill-downloads/web-application-testing-mrwakgh4/SKILL.md' && test -s '.skill-downloads/web-application-testing-mrwakgh4/SKILL.md' && mkdir -p '.agents/skills' && test ! -e '.agents/skills/webapp-testing' && cp -R '.skill-downloads/web-application-testing-mrwakgh4' '.agents/skills/webapp-testing'

OpenSkills

OpenSkills must already be installed. The local install/read procedure is checked with OpenSkills 1.5.0, which requires Node.js ≥ 20.6.0. Catalog slugs are not resolved automatically.

Official OpenSkills installation
openskills install './.skill-downloads/web-application-testing-mrwakgh4'

openskills read 'web-application-testing-mrwakgh4'

Reading should display the installed file content and its base directory. It does not run the skill or install its dependencies.

For an agent that reads AGENTS.md, then sync the index. This command changes AGENTS.md: review the diff before using it.

openskills sync

Manual method or another tool: attach SKILL.md to a conversation, or open it in an agent that can read files. Include any required supporting resources. No universal folder is recognized by every tool.

4. Try a first task

Use a short, synthetic input: an API endpoint, a small document or an interface brief. In a new conversation, attach the file or give the agent its path, then adapt this request:

Read .skill-downloads/web-application-testing-mrwakgh4/SKILL.md and apply its instructions to this example: [describe a test input]. Identify any missing files, dependencies or access. Produce the result requested by the skill without inventing data or running unreviewed scripts.

Expected result: output matching the skill instructions, or a precise list of missing prerequisites. A read confirmation alone does not validate a first use. If an external resource is unavailable, that path remains untested.

Related skills