[Web Testing] Automated visual regression, link checking, form testing, and console error auto-fix #60

Open
opened 2026-04-06 23:51:49 +00:00 by NW · 0 comments
Owner

User Story

As a developer building web applications, I need automated testing that detects visual regressions (overlapping elements, broken fonts, wrong colors), checks all links and forms, captures console errors, and auto-fixes them � so that I catch UI bugs before they reach production.

Acceptance Criteria

1. Visual Regression Testing

  • Take screenshots of all pages at 3 viewports (mobile 375px, tablet 768px, desktop 1280px)
  • Compare with baseline using pixelmatch
  • Detect: overlapping elements, font shifts, color mismatches, missing backgrounds
  • Generate diff images (baseline/current/diff)
  • HTML report with visual comparison
  • Crawl all pages and find all tags
  • Click each link and check for 404/500 errors
  • Report broken links with page URL and link text

3. Form Testing

  • Find all elements on each page
  • Fill all input fields with valid test data
  • Submit and verify response (success/error handling)
  • Test empty field validation
  • Test invalid data (SQL injection, XSS payloads)

4. Console Error Detection

  • Capture all console.error() and console.warn()
  • Capture uncaught exceptions
  • Capture network errors (failed XHR/fetch)
  • Report: error message, file, line number, stack trace

5. Auto-Fix Pipeline

  • Console errors create Gitea Issues automatically
  • @the-fixer agent analyzes error and proposes fix
  • @lead-developer implements the fix
  • Tests re-run to verify fix
  • PR created with fix

Architecture

Docker (no host pollution)

Kilo Code Integration

Tool Purpose
HTTP requests to Playwright MCP
Run docker-compose, pixelmatch
Delegate to @visual-tester, @the-fixer

Test Flow

Files to Create

    • Playwright MCP container
    • Testing skill documentation
    • /web-test command
    • /web-test-fix command (with auto-fix)
    • Baseline screenshots directory
    • Current screenshots
    • Diff images
    • HTML reports
    • Visual comparison script
    • Link validation script
    • Form testing script

Expected Output

Visual Regression Report

Console Error Report

Milestone

Phase 0: Infrastructure - Docker Compose for MCP servers #54

## User Story As a developer building web applications, I need automated testing that detects visual regressions (overlapping elements, broken fonts, wrong colors), checks all links and forms, captures console errors, and auto-fixes them � so that I catch UI bugs before they reach production. ## Acceptance Criteria ### 1. Visual Regression Testing - [ ] Take screenshots of all pages at 3 viewports (mobile 375px, tablet 768px, desktop 1280px) - [ ] Compare with baseline using pixelmatch - [ ] Detect: overlapping elements, font shifts, color mismatches, missing backgrounds - [ ] Generate diff images (baseline/current/diff) - [ ] HTML report with visual comparison ### 2. Link Checking - [ ] Crawl all pages and find all <a> tags - [ ] Click each link and check for 404/500 errors - [ ] Report broken links with page URL and link text ### 3. Form Testing - [ ] Find all <form> elements on each page - [ ] Fill all input fields with valid test data - [ ] Submit and verify response (success/error handling) - [ ] Test empty field validation - [ ] Test invalid data (SQL injection, XSS payloads) ### 4. Console Error Detection - [ ] Capture all console.error() and console.warn() - [ ] Capture uncaught exceptions - [ ] Capture network errors (failed XHR/fetch) - [ ] Report: error message, file, line number, stack trace ### 5. Auto-Fix Pipeline - [ ] Console errors create Gitea Issues automatically - [ ] @the-fixer agent analyzes error and proposes fix - [ ] @lead-developer implements the fix - [ ] Tests re-run to verify fix - [ ] PR created with fix ## Architecture ### Docker (no host pollution) ### Kilo Code Integration | Tool | Purpose | |------|---------| | | HTTP requests to Playwright MCP | | | Run docker-compose, pixelmatch | | | Delegate to @visual-tester, @the-fixer | ### Test Flow ## Files to Create - - Playwright MCP container - - Testing skill documentation - - /web-test command - - /web-test-fix command (with auto-fix) - - Baseline screenshots directory - - Current screenshots - - Diff images - - HTML reports - - Visual comparison script - - Link validation script - - Form testing script ## Expected Output ### Visual Regression Report ### Console Error Report ### Link Check Report ## Milestone Phase 0: Infrastructure - Docker Compose for MCP servers #54
Sign in to join this conversation.