✅(e2e) add threshold in regression test
When comparing PDF screenshots, we can have some minor differences due to the different environments (OS, fonts, etc.). To avoid false positives in our regression tests, we can set a threshold for the number of different pixels allowed before considering the test as failed. If the test fails we will now report the PDF and the differences to identify quickly what are the regressions.
This commit is contained in:
@@ -22,8 +22,11 @@
|
||||
"typescript": "*"
|
||||
},
|
||||
"dependencies": {
|
||||
"@types/pngjs": "6.0.5",
|
||||
"convert-stream": "1.0.2",
|
||||
"pdf-parse": "2.4.5"
|
||||
"pdf-parse": "2.4.5",
|
||||
"pixelmatch": "7.1.0",
|
||||
"pngjs": "7.0.0"
|
||||
},
|
||||
"packageManager": "yarn@1.22.22"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user