webapp-testing

Automate testing of local web applications using Playwright browser scripts.

Updated Sep 11, 2026
One-click install
npx skills add https://github.com/CYRUS-pinto/pi-bot --skill webapp-testing-cyrus-pinto
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: webapp-testing
Source: https://github.com/CYRUS-pinto/pi-bot/tree/main/.agents/skills/webapp-testing
Command: npx skills add https://github.com/CYRUS-pinto/pi-bot --skill webapp-testing-cyrus-pinto

SYSTEM DOCUMENTATION & REQUIREMENTS

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

What problem does it solve? Testing local web applications manually is slow and error-prone, especially when verifying frontend behavior, debugging UI issues, or capturing browser state. This Skill provides a structured Playwright-based workflow for automating browser interactions against local servers. ## Core Features & Use Cases - Server Lifecycle Management: The with_server.py helper starts one or more servers (e.g., backend plus frontend), waits for readiness, runs your automation, and cleans up afterward. - Reconnaissance-Then-Action Pattern: Inspect the rendered DOM after networkidle, identify selectors, then execute actions reliably on dynamic apps. - Example Scripts: Ready-made patterns for element discovery, static HTML automation via file:// URLs, and console log capture. - Use Case: You have a React frontend on port 5173 and a Python backend on port 3000. Use the helper to launch both, then run a Playwright script that logs in, clicks through the dashboard, and captures screenshots and console logs for debugging. ## Quick Start Ask the AI to test your local web app with Playwright, for example: start my dev server and verify the login form works on localhost:5173.

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 sync_playwright, launch Chromium in headless mode, navigate to your local server URL, and wait for networkidle before interacting. Use the with_server.py helper to start your dev server automatically before the script runs.

How to run Playwright tests against multiple servers at once?

Pass multiple --server and --port pairs to with_server.py, such as a backend on port 3000 and a frontend on port 5173. The script starts each server, waits for its port to respond, runs your command, then terminates all servers.

Why does Playwright fail to find elements on dynamic web apps?

Elements are missing because the DOM was inspected before JavaScript finished rendering. Always call page.wait_for_load_state('networkidle') after navigation, then take a screenshot or inspect the DOM to discover the actual selectors.

Can Playwright automate static HTML files without a server?

Yes, Playwright can open local HTML files directly using file:// URLs built from the absolute file path. You can then click elements, fill forms, and capture screenshots exactly as with a served page.

How do I capture browser console logs during Playwright automation?

Register a handler with page.on('console', handler) before navigating. Each console message is passed to your callback, where you can print it or collect messages into a list and save them to a log file after the browser closes.