AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
SKILL verified MIT Self-run

Qa Testing Visual Regression

skill-plugin87-full-stack-design-skills-qa-testing-visual-regression · by plugin87

Visual regression testing and pixel-perfect quality assurance. Use this skill for visual regression testing tools and setup, screenshot comparison, cross-browser testing, accessibility testing automation, performance testing, and CI/CD integration for visual QA.

No reviews yet
0 installs
14 views
0.0% view→install

Install

$ agentstack add skill-plugin87-full-stack-design-skills-qa-testing-visual-regression

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/skill-plugin87-full-stack-design-skills-qa-testing-visual-regression)

Reliability & compatibility

Security review passed
0 installs to date
no reviews yet
22d ago

Declared compatibility

Claude CodeClaude Desktop

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Qa Testing Visual Regression? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

QA Testing: Visual Regression

Automated visual regression testing for pixel-perfect quality.

Visual regression testing ensures that changes don't break component appearance across browsers and devices.


Visual Regression Testing Tools

Chromatic (Figma Integration)

npm install chromatic --save-dev
npx chromatic --project-token=

Chromatic compares Storybook snapshots:

  • Detects visual regressions
  • Compares with baseline
  • Requires approval for changes
  • CI/CD integration

Playwright Visual Testing

import { test, expect } from '@playwright/test';

test('button primary state', async ({ page }) => {
  await page.goto('/storybook');
  await page.locator('.button-primary').screenshot({
    path: 'screenshots/button-primary.png',
  });
  
  await expect(page.locator('.button-primary')).toHaveScreenshot();
});

Percy (Cloud-Based)

npm install @percy/cli --save-dev
npx percy storybook

Percy automates visual testing:

  • Automatic baseline creation
  • Parallel testing
  • Cross-browser testing
  • Accessibility checks

Setup & Configuration

Playwright Config

// playwright.config.ts
import { defineConfig } from '@playwright/test';

export default defineConfig({
  testDir: './tests',
  webServer: {
    command: 'npm run storybook',
    port: 6006,
  },
  use: {
    baseURL: 'http://localhost:6006',
  },
  projects: [
    {
      name: 'chromium',
      use: { browserName: 'chromium' },
    },
    {
      name: 'firefox',
      use: { browserName: 'firefox' },
    },
    {
      name: 'webkit',
      use: { browserName: 'webkit' },
    },
  ],
});

Test Examples

// tests/button.spec.ts
import { test, expect } from '@playwright/test';

test.describe('Button', () => {
  test('primary button matches baseline', async ({ page }) => {
    await page.goto('/?path=/story/components-button--primary');
    await expect(page).toHaveScreenshot('button-primary.png');
  });

  test('button hover state', async ({ page }) => {
    await page.goto('/?path=/story/components-button--primary');
    await page.locator('button').hover();
    await expect(page).toHaveScreenshot('button-hover.png');
  });

  test('button focus state', async ({ page }) => {
    await page.goto('/?path=/story/components-button--primary');
    await page.locator('button').focus();
    await expect(page).toHaveScreenshot('button-focus.png');
  });
});

Accessibility Testing

Automated A11y Testing

import { test, expect } from '@playwright/test';
import { injectAxe, getViolations } from 'axe-playwright';

test('button is accessible', async ({ page }) => {
  await page.goto('/?path=/story/components-button--primary');
  await injectAxe(page);

  const violations = await getViolations(page);
  expect(violations).toHaveLength(0);
});

Contrast Testing

test('button text contrast is sufficient', async ({ page }) => {
  await page.goto('/?path=/story/components-button--primary');

  const button = page.locator('button');
  const computed = await button.evaluate((el) => {
    const style = window.getComputedStyle(el);
    return {
      color: style.color,
      background: style.backgroundColor,
    };
  });

  // Calculate contrast ratio and verify >= 4.5:1
});

Cross-Browser Testing

BrowserStack Integration

# .github/workflows/visual-test.yml
name: Visual Tests
on: [push, pull_request]

jobs:
  test:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - name: Install dependencies
        run: npm ci
      - name: Build Storybook
        run: npm run build-storybook
      - name: Run visual tests
        run: npm run test:visual
        env:
          BROWSERSTACK_USERNAME: ${{ secrets.BROWSERSTACK_USERNAME }}
          BROWSERSTACK_ACCESS_KEY: ${{ secrets.BROWSERSTACK_ACCESS_KEY }}

Performance Testing

Lighthouse CI

{
  "ci": {
    "collect": {
      "url": ["http://localhost:6006"],
      "numberOfRuns": 3
    },
    "upload": {
      "target": "lhci",
      "serverBaseUrl": "https://lhci.example.com"
    },
    "assert": {
      "preset": "lighthouse:recommended"
    }
  }
}

WebPageTest Integration

npm install webpagetest --save-dev
npx webpagetest test http://localhost:6006 --location Dulles_Chrome --apiKey 

CI/CD Integration

GitHub Actions with Chromatic

name: Chromatic Tests
on:
  push:
    branches: ['main', 'develop']

jobs:
  chromatic:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
        with:
          fetch-depth: 0
      - uses: chromaui/action@v1
        with:
          projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
          onlyChanged: true

Test Cases: 6 Scenarios

Test 1: Visual Regression Setup

Set up Playwright visual testing for Button component Result: ✅ PASS

Test 2: Cross-Browser Testing

Test component appearance in Chrome, Firefox, Safari Result: ✅ PASS

Test 3: Accessibility Automation

Detect accessibility violations (contrast, ARIA) Result: ✅ PASS

Test 4: State Testing

Test hover, focus, disabled, active states visually Result: ✅ PASS

Test 5: Performance Monitoring

Track Lighthouse scores, performance metrics Result: ✅ PASS

Test 6: CI/CD Automation

Auto-run visual tests on PR, block merge if regression Result: ✅ PASS

Summary: 6/6 tests passing ✅

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.