Skip to content

Commit fdbbe6f

Browse files
committed
fix(screenshot): adjust maxDiffPixelRatio for mobile projects to account for layout differences
1 parent bdfb8fc commit fdbbe6f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

showcases/e2e/default.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,9 @@ export const getDefaultScreenshotTest = ({
125125
config.maxDiffPixelRatio = 0.033;
126126
} else if (isAngular(showcase)) {
127127
config.maxDiffPixels = 1000;
128+
} else if (project.name.startsWith('mobile')) {
129+
// Mobile Chrome can have minor anti-aliasing/layout differences; allow small ratio
130+
config.maxDiffPixelRatio = 0.015;
128131
} else {
129132
config.maxDiffPixels = 120;
130133
}

0 commit comments

Comments
 (0)