webapp-testing

Automate browser testing of local web applications using Python Playwright scripts.

Updated Aug 2, 2026
One-click install
npx skills add https://github.com/leonardoacosta/skills --skill webapp-testing-leonardoacosta
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: webapp-testing
Source: https://github.com/leonardoacosta/skills/tree/main/web-frontend-kit/skills/webapp-testing
Command: npx skills add https://github.com/leonardoacosta/skills --skill webapp-testing-leonardoacosta

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires playwright, and includes scripts (resource) components.

What problem does it solve? Verifying that a frontend change actually renders and behaves correctly requires more than compiling code; this Skill automates real browser interaction against running dev servers so you can reproduce bugs, inspect rendered DOM elements, and capture screenshots or console logs without manual clicking. ## Core Features & Use Cases - Server Lifecycle Management: The with_server.py helper starts one or more dev servers, polls ports until ready, runs your automation, and cleans up processes afterward. - Reconnaissance-Then-Action Pattern: Inspect the rendered DOM after networkidle to discover actual buttons, links, and inputs before writing selectors, avoiding guesses from static markup. - Console and Screenshot Capture: Example scripts show how to persist console output and full-page screenshots for debugging runtime JavaScript errors. - Use Case: A bug report says a form submit button does nothing. Start the dev server with the helper, run a Playwright script that navigates, waits for network idle, discovers the real button selector, clicks it, and captures the console log showing the underlying JavaScript error. ## Quick Start Use the webapp-testing skill to start my dev server on port 5173 and verify the login form renders and submits correctly.

Frequently Asked Questions about webapp-testing

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I test a local web application with Playwright in Python?

Write a Python script using playwright.sync_api, launch Chromium in headless mode, navigate to your localhost URL, and call page.wait_for_load_state('networkidle') before interacting. Use the with_server.py helper to start and stop your dev server automatically around the script.

How to find selectors for buttons and inputs on a dynamic page?

Use the reconnaissance-then-action pattern: navigate, wait for networkidle, then enumerate elements with page.locator('button').all() or inspect page.content(). Never trust selectors read from static source HTML, since client-rendered content can differ from the initial markup.

Can Playwright automate static HTML files without a dev server?

Yes, Playwright can open local files directly using file:// URLs constructed from absolute paths. The static_html_automation.py example shows this pattern with a fixed 1920x1080 viewport for deterministic screenshots.

Why does my Playwright script miss elements on a dynamic app?

The script likely inspects the DOM before client-side rendering finishes. Always call page.wait_for_load_state('networkidle') after page.goto() so JavaScript-rendered content exists before resolving selectors, and avoid fixed sleep-based waits.

How do I capture browser console logs during automated testing?

Register a handler with page.on('console', handler) before navigating, append each message to a list during the session, and write the collected logs to a file after browser.close(). The console_logging.py example demonstrates this full pattern.