Skip to content
View mapvisualregression's full-sized avatar

Block or report mapvisualregression

Block user

Prevent this user from interacting with your repositories and sending you notifications. Learn more about blocking users.

You must be logged in to block users.

Maximum 250 characters. Please don’t include any personal information such as legal names or email addresses. Markdown is supported. This note will only be visible to you.
Report abuse

Contact GitHub support about this user’s behavior. Learn more about reporting abuse.

Report abuse

Automated Map Visual Regression & Web Mapping Testing

Automated Map Visual Regression & Web Mapping Testing

The engineering reference for reliable visual regression testing of dynamic web maps.
www.mapvisualregression.org


Web maps break the assumptions that generic UI snapshot tools are built on. A login form settles into a single, static layout; a slippy map does not. It combines asynchronous tile loading, WebGL rasterization, GPU-dependent anti-aliasing, dynamic vector styling, label-collision engines, and continuous animation loops — so a single screenshot becomes a synchronization problem. A shifted label halo or a misaligned scale bar is a real regression, yet the same renderer can legitimately produce thousands of differing pixels between two correct runs.

Map Visual Regression is a deep, practitioner-focused resource that collapses that variability into deterministic, repeatable states — so your pixel diffs mean genuine cartographic faults, not rendering noise. Every page is a hands-on engineering guide with runnable code, tuned thresholds, custom diagrams, and battle-tested failure-mode tables.

Who it's for

Frontend GIS developers, QA engineers, mapping-platform teams, and DevOps practitioners building or maintaining a visual-regression pipeline for MapLibre GL, Mapbox GL, Leaflet, or OpenLayers.

What it covers

  • Web Map Visual Testing Fundamentals & Toolchains — deterministic rendering, versioned baseline architecture, diff-algorithm selection, containerized rendering environments, and choosing between commercial and open-source toolchains.
  • Screenshot Capture, Sync & Comparison Logic — the capture-and-compare core: waiting for tile hydration, WebGL idle and render-completion detection, viewport/camera synchronization, and zoom-aware threshold tuning.
  • Dynamic Element Masking & UI Stability — masking cursors, tooltips, popups, and attribution; suppressing animations; stabilizing marker clustering; and freezing animated weather and traffic tile layers.
  • CI/CD Integration & Visual Test Operations — GitHub Actions and GitLab CI gates with real threshold enforcement, cross-browser baseline matrices, flaky-test triage and quarantine, and the cost and scaling of large screenshot suites.

Why it's different

  • Map-specific, not generic UI testing. Every technique centers on the peculiarities of geospatial rendering: tile pyramids, GPU driver variance, font-stack drift, and label collision.
  • Runnable, real code. Playwright/Puppeteer harnesses, headless Chromium flags, CI YAML, and diff-tuning snippets you can lift straight into a pipeline.
  • Precise thresholds. Zoom-aware tolerance tables, SSIM and perceptual-hash calibration, and KaTeX-rendered formulas where mathematical precision aids the reader.
  • Custom diagrams. Hand-authored, theme-aware SVG architecture, sequence, and decision diagrams on every major page — no stock imagery.
  • Named failure modes. Diagnostic tables mapping symptom → root cause → fix for the flaky-render patterns that actually happen in production.

Built with

A fast, dependency-light Eleventy static site, shipped as an offline-ready Progressive Web App and deployed on Cloudflare. Content is authored in Markdown with structured data (Article, HowTo, FAQPage, BreadcrumbList), accessible SVG visuals, and KaTeX math.

Explore

Start at www.mapvisualregression.org and follow the in-context links — every guide is one or two clicks from the topic you need.

License

Content and code © Map Visual Regression. Released under the MIT License.

Popular repositories Loading

  1. mapvisualregression mapvisualregression Public

    Engineering guides for reliable automated visual regression testing of web maps — screenshot capture, tile sync, WebGL rendering, dynamic element masking, and CI gating for MapLibre GL, Mapbox GL, …

    JavaScript