mirror of
https://github.com/lovell/sharp.git
synced 2025-12-19 07:15:08 +01:00
Add private maxColourDistance for functional tests
Switch MSE-based tests to use it Remove experimental MSE-based compare API
This commit is contained in:
@@ -83,8 +83,12 @@ describe('Alpha transparency', function() {
|
||||
.resize(2048, 1536)
|
||||
.interpolateWith('bicubic')
|
||||
.toFile(actual, function(err) {
|
||||
if (err) throw err;
|
||||
fixtures.assertEqual(actual, expected, done);
|
||||
if (err) {
|
||||
done(err);
|
||||
} else {
|
||||
fixtures.assertMaxColourDistance(actual, expected, 102);
|
||||
done();
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
@@ -96,8 +100,12 @@ describe('Alpha transparency', function() {
|
||||
.resize(1024, 768)
|
||||
.interpolateWith('bicubic')
|
||||
.toFile(actual, function(err) {
|
||||
if (err) throw err;
|
||||
fixtures.assertEqual(actual, expected, done);
|
||||
if (err) {
|
||||
done(err);
|
||||
} else {
|
||||
fixtures.assertMaxColourDistance(actual, expected, 102);
|
||||
done();
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user