October DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsSlow PC?RecommendedPC slow today? Run a repair scan before it gets worseResolve common Windows issues and optimize system performance.Scan NowOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
World desk6 min

How to Run Visual Regression Tests for an Angular Website in Jenkins

Use Playwright Test to compare Angular pages against reviewed screenshot baselines, then run the suite in a consistent Docker environment on Jenkins.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Use Playwright Test to render Angular pages in a real browser, compare them with committed screenshot baselines, and run the checks in a version-matched Playwright Docker agent on Jenkins. Angular unit tests are not a substitute: they test units, while visual regression checks rendered browser output.

Why use browser-based tests for Angular visual regression?

Angular’s current testing overview describes unit tests using Vitest and jsdom for new projects, and separately covers running tests in a real browser with providers that include Playwright. Its E2E guide describes ng e2e as a builder entry point and lists Playwright among available integrations. The Angular CLI does not prescribe a visual-testing framework, so choose and configure an E2E runner for the project rather than treating unit tests as screenshot comparisons. See Angular’s testing overview and Angular’s E2E guide.

As an Amazon Associate I earn from qualifying purchases.

With Playwright Test, an assertion such as await expect(page).toHaveScreenshot() creates a reference image on its first run and compares later renders with that baseline. The reference is an expected result to review, not proof that the interface is correct. Keep approved snapshots with the test code in version control so proposed changes are visible in pull requests. See Playwright screenshot comparisons.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Configure a stable Angular screenshot test

Choose a route and state that can be reproduced

Use a route that Jenkins can load reliably and arrange the page into a known state before capturing. Keep viewport dimensions and test data stable. Wait for meaningful content to appear and settle; otherwise, delayed data or rendering can make a screenshot differ even when the intended UI has not changed.

#1 Best Overall
Arducam 8MP USB Camera Module with HDR, Autofocus Lightburn Camera, USB 2.0 Webcam with Multiple preset AI Resolutions for Raspberry Pi, Windows, Linux, Android, Mac OS
  • Plug-and-Play USB Camera Module: Experience ultimate convenience with our plug-and-play USB camera module. This 8MP camera is instantly recognized by Windows, Linux, Android, and macOS without any extra drivers. Just connect the USB and immediately start capturing crisp images, making it a perfect mini USB camera for rapid deployment in any project
  • AI Resolution for Advanced Applications: Leverage multiple preset AI image resolutions to train and deploy your models seamlessly. This USB webcam and 3D printer camera eliminates the need for manual image cropping, delivering ready-to-process data straight from the sensor. It’s an ideal vision solution for developers and makers
  • Autofocus & High-Definition Clarity: Equipped with a premium autofocus lens, this 4K mini camera automatically adjusts to maintain sharpness at various distances. Whether you’re using it as a lightburn camera for laser engraver or for detailed inspection, it delivers consistently clear and professional USB camera 4K quality video
  • Robust & Reliable USB Security Camera: Built for durability and performance, this USB security camera offers steadfast monitoring with high-resolution imaging. Its versatile mounting and plug-and-play operation make it suitable for both home security setups and professional surveillance systems
  • Upgraded Option with HDR: The enhanced model includes High Dynamic Range (HDR), an autofocus lens, and a rugged metal case. This upgraded USB camera module is especially suited for demanding applications like laser engraving with LightBurn or as a high-end 3D printer camera

Rendering can vary with the operating system, browser version, browser settings, hardware, power source, and headless mode. Create and compare baselines in the same environment where possible. A consistent Docker agent and deliberately pinned browser and Playwright versions reduce avoidable variation; they do not eliminate changes caused by genuinely different page content.

Write the screenshot assertion

For example, a Playwright Test file can navigate to a stable application route and assert a named screenshot:

Rank #2
Dell Pro 16 Plus PB16255 Laptop, 16" FHD+, AMD Ryzen AI 7 PRO 350, 32GB/2TB
  • ENGINEERED FOR AI & MOBILITY - Meet the Dell Pro 16 Plus, the AI-enhanced evolution of the Latitude 5550. Engineered for on-the-go productivity, it features a slim and lightweight design, delivers up to 11.9 hours of battery life, and supports ExpressCharge capability to keep you efficient. Boasting a durable aluminum chassis and having passed MIL-STD 810H tests, it offers robust reliability for professionals on the move, from the office to demanding field environments
  • POWERFUL PERFORMANCE – The Dell Pro 16 Plus delivers power-efficient performance for demanding workloads with an AI PC powered by the AMD Ryzen AI 7 PRO 350 processor (up to 5.0GHz) and integrated Radeon 860M Graphics. Equipped with 32GB LPDDR5x RAM and 2TB M.2 NVMe PCIE SSD, enabling smooth multitasking and fast loading across a wide range of applications
  • COPILOT+ PC AI POWERHOUSE - The dedicated NPU delivers 50 TOPS for local AI processing without relying on the cloud. It enables Recall (effortless retrieval of past actions and content), Cocreate (AI image tools), Windows Studio Effects (auto-framing/background blur for video calls), and Live Captions (real-time translation). It redefines productivity and creativity with seamless, offline AI acceleration
  • IMMERSIVE DISPLAY - Features a 16-inch WUXGA (1920x1200) display with narrow borders, 300 nits brightness, and anti-glare coating to maximize screen real estate and reduce eye strain during extended use. Expand your workspace by connecting up to 3 external monitors via HDMI or Thunderbolt 4, with a max resolution of up to 4K@60Hz without docking station
  • ADVANCED CONNECTIVITY -With Thunderbolt 4, USB-A, and HDMI 2.1, MicroSD card reader, Global Headset Jack and RJ45 Ethernet port, you can easily connect external displays, storage devices, and essential peripherals. Stay fast and reliable on the go with Wi-Fi 7 and Bluetooth 5.4, perfect for video calls, cloud work, and wireless devices without lag. The 1080p IR camera with temporal noise reduction ensures crisp video calls in any lighting and secure facial recognition login. Plus, the backlit keyboard enables precise typing in low-light environments
import { test, expect } from '@playwright/test';

test('account page visual appearance', async ({ page }) => {
  await page.goto('http://127.0.0.1:4200/account');
  await expect(page).toHaveScreenshot('account-page.png');
});

Start the Angular app as part of your test setup or pipeline so the route is available at the address your test uses. The example assumes the app is already serving locally; configure the project’s web-server or startup step accordingly. Choose descriptive screenshot names to make failures and snapshot changes easier to identify.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Control unstable page content carefully

Remove or stabilize content that changes independently of the code under test, such as timestamps, rotating promotions, animations, or remote data. Playwright supports a stylePath screenshot option; its documentation shows hiding iframes as one way to filter volatile content. Avoid broad masking or hiding rules that could conceal a real visual regression.

Rank #3
Software Engineer Definition Sticker - Funny Programmer Vinyl Decal - 5 in
  • Size: 5" x 4.6"
  • Al weather vinyl sticker
  • Phone sticker, laptop sticker, car sticker, water bottle sticker, and so many more applications!
  • Peel & stick, simple application, reusable
  • Made in the USA

Playwright’s maxDiffPixels option can permit a specified number of differing pixels. Use a threshold only when the team understands what variation it allows. A generous threshold can cause meaningful changes to pass unnoticed; it should not be a blanket way to turn failing tests green.

Run Playwright visual tests in Jenkins

Playwright’s CI guidance recommends its Docker image for Jenkins and illustrates this minimal pipeline pattern. The v1.63.0-noble image tag below is the version shown in that documentation when researched, not a timeless recommendation. Use an image version aligned with the Playwright version installed in your project, pin the pair deliberately, and update them intentionally. Jenkins agents must be configured to use Docker.

Rank #4
Web Developer Coding Skeleton In Front of Laptop Halloween T-Shirt
  • For programmers and web developers who have a sense of gothic macabre about them. Perfect for coding meetups, gaming sessions, or casual outings. Do you live for code? Are you a programmer, IT professional or developer who is constantly coding?
  • Web Developer Coding Skeleton In Front of Laptop Halloween. Perfect for dark mode developers, programmers, software engineers, anyone in tech with a dark side who lives at their computer. Great for Halloween or the rest of the year.
  • Lightweight, Classic fit, Double-needle sleeve and bottom hem
pipeline {
  agent { docker { image 'mcr.microsoft.com/playwright:v1.63.0-noble' } }
  stages {
    stage('visual tests') {
      steps {
        sh 'npm ci'
        sh 'npx playwright test'
      }
    }
  }
}

This example installs the locked dependencies with npm ci and runs the Playwright suite. It does not start an Angular server or publish test artifacts; add the project-specific startup and Jenkins artifact-retention steps needed for your setup. See Playwright’s Jenkins CI guidance.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Generate, review, and update baselines

  1. Run the tests in the intended environment. The first run creates expected screenshot files; subsequent runs compare rendered pages against them.
  2. Review the first baseline in a pull request. Confirm that the captured UI is the intended design before accepting the image into version control.
  3. Investigate later failures. Inspect the actual screenshot and generated diff to distinguish a real change from unstable content or an environment mismatch.
  4. Update snapshots only for approved UI changes. Run npx playwright test --update-snapshots, inspect the resulting image changes, and commit the new baseline alongside the code change.
  5. Retain diagnostics in Jenkins. Configure your installation and report setup to preserve Playwright reports, actual and expected screenshots, and diffs where generated. Artifact publishing is not included in the minimal Jenkins example above.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Local baselines or hosted visual review?

Playwright’s native screenshot assertions compare against reference images kept with the repository. That gives the team direct ownership of snapshot files and makes baseline changes reviewable alongside code. Percy documents a Playwright integration that can route screenshot assertions through its service and offers an optional CI gate for changes. That adds a hosted review path rather than replacing the local-baseline workflow in every project. The cited documentation does not establish current pricing or commercial terms, so assess those separately before adopting it. See Percy’s Playwright integration documentation.

Best Value
I Turn Coffee Into Code Funny Programmer Sticker - Software Engineer Vinyl Decal for Laptops, Monitors, and Water Bottles - Coding & Tech Humor - Durable, Waterproof Die-Cut Tech Sticker
  • The Ultimate Developer Humor: Celebrate the fuel behind your best lines of code with this "I Turn Coffee Into Code" sticker. It is a must-have accessory for software engineers, web developers, data scientists, and computer science students.
  • Premium Waterproof & Heat-Resistant: Crafted from high-quality, durable vinyl that is 100% waterproof and heat-resistant. Perfect for sticking on high-performance laptops, coffee tumblers, or office water bottles without worrying about peeling or fading.
  • Sleek Professional Design: Featuring a bold black and white aesthetic with a clean coffee cup icon, this die-cut decal looks professional and stylish on MacBooks, PC cases, and office monitors.
  • Easy Application, Zero Residue: Equipped with a strong adhesive that stays put through daily wear. If you upgrade your hardware, it peels off cleanly without leaving any sticky mess or residue behind on your expensive electronics.
  • Perfect Tech Gift: Looking for a great gift for a programmer, IT professional, or coding student? This decal makes an excellent stocking stuffer, "new job" gift, or secret santa present for your tech-savvy coworkers.

Neither approach removes the need to keep rendering conditions consistent: screenshot diffs are sensitive to environment and page state. The choice is principally about where snapshots and review live, how the team inspects changes, and what CI behavior it wants. The cited materials do not establish an independent cost or performance comparison.

Troubleshooting common failures

  • Every screenshot differs in Jenkins. Check that the Playwright package and Docker image versions match, and that baseline creation and CI use a consistent browser and operating environment. Also check viewport and test data.
  • The first run fails because no baseline exists. Generate the reference screenshot, review it as a proposed expected result, and commit it before treating later comparisons as meaningful.
  • Images or page sections are missing intermittently. Ensure the test waits for the content that matters and that the app and its data are available. Stabilize delayed or remote content rather than assuming navigation completion means the page is visually settled.
  • Unrelated dynamic content causes noise. Stabilize the source or use a narrowly scoped screenshot style such as Playwright’s documented stylePath approach. Do not hide broad areas that could contain real regressions.
  • A changed screenshot is expected. Inspect the diff, then update with npx playwright test --update-snapshots and commit the reviewed images with the UI change.
  • Jenkins cannot start the Docker agent. The Jenkins agent must be configured to support Docker; resolve that infrastructure requirement before changing the test assertion.

Or skip the browser setup

ScreenshotNeo is a website screenshot API and MCP server by Yorker Media. For a one-request screenshot outside the Angular/Playwright baseline workflow, call its API with the target URL:

curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp

See the ScreenshotNeo API documentation for setup and options. It accepts cookie or consent banners like a visitor and removes more than 60 known consent platforms, newsletter popups, and chat widgets before capture; each step can be turned off. Bot checks/CAPTCHAs, blank pages, timeouts, failed loads, and cache hits are not billed, and response headers report the page verdict and billing status. Its MCP server provides take_screenshot, get_page_info, and capture_pdf for Claude, Cursor, and other MCP clients. The free plan includes 1,000 shots a month without a card; paid plans start at $5 for 3,000 shots.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Sign up for ScreenshotNeo’s free plan to get 1,000 screenshots a month with no card.

Frequently Asked Questions

Does Angular’s ng e2e command create visual regression tests by itself?

No. It is an E2E builder entry point; configure a browser runner such as Playwright and add screenshot assertions for visual comparisons.

Can I use Playwright screenshot baselines with Percy?

Percy documents a Playwright integration that routes screenshot assertions through Percy and can provide an optional CI gate. It is a hosted review option alongside the native repository-baseline approach.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Outdated Drivers Are Slowing You DownFree scan - exact matches
PC Slower Than It Used to Be?Free scan - under a minute

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.