Files
klz-cables.com/backstop.config.js
Marc Mintel 8c9f51b74a
Some checks failed
Build & Deploy / 🔍 Prepare (push) Successful in 6s
Build & Deploy / 🧪 QA (push) Successful in 1m52s
Build & Deploy / 🏗️ Build (push) Successful in 4m1s
Build & Deploy / 🚀 Deploy (push) Successful in 28s
Build & Deploy / ⚡ Lighthouse (push) Successful in 3m0s
Build & Deploy / 🧪 Smoke Test (push) Successful in 3m13s
Build & Deploy / ♿ WCAG (push) Failing after 1m48s
Build & Deploy / 🔔 Notify (push) Has been cancelled
Build & Deploy / 📸 Visual Diff (push) Has been cancelled
chore(ci): Setup visual regression testing with BackstopJS
2026-02-21 23:30:22 +01:00

67 lines
1.6 KiB
JavaScript

/* eslint-disable */
module.exports = {
id: 'klz-cables',
viewports: [
{
label: 'phone',
width: 375,
height: 667,
},
{
label: 'tablet',
width: 768,
height: 1024,
},
{
label: 'desktop',
width: 1440,
height: 900,
},
],
onBeforeScript: 'puppet/onBefore.js',
onReadyScript: 'puppet/onReady.js',
scenarios: [
{
label: 'Homepage',
url: `${process.env.TEST_URL || 'http://host.docker.internal:3000'}/`,
referenceUrl: '',
readyEvent: '',
readySelector: '',
delay: 500,
hideSelectors: [],
removeSelectors: [],
hoverSelector: '',
clickSelector: '',
postInteractionWait: 0,
selectors: [],
selectorExpansion: true,
expect: 0,
misMatchThreshold: 0.1,
requireSameDimensions: true,
},
{
label: '404 Error Page',
url: `${process.env.TEST_URL || 'http://host.docker.internal:3000'}/this-page-does-not-exist`,
delay: 500,
misMatchThreshold: 0.1,
},
],
paths: {
bitmaps_reference: 'backstop_data/bitmaps_reference',
bitmaps_test: 'backstop_data/bitmaps_test',
engine_scripts: 'backstop_data/engine_scripts',
html_report: 'backstop_data/html_report',
ci_report: 'backstop_data/ci_report',
},
report: process.env.CI ? ['CI'] : ['browser'],
engine: 'puppeteer',
engineOptions: {
args: ['--no-sandbox', '--disable-setuid-sandbox'],
executablePath: process.env.CHROME_PATH || undefined, // Use explicit Chrome in CI
},
asyncCaptureLimit: 5,
asyncCompareLimit: 50,
debug: false,
debugWindow: false,
};