Backed out changeset f5f5cbb377ac (bug 1563358) for eslint failure at /marionette/reftest.js on a CLOSED TREE.

This commit is contained in:
Gurzau Raul 2019-08-01 00:23:04 +03:00
Родитель e9fbe40bae
Коммит a86cf65c2c
1 изменённых файлов: 6 добавлений и 8 удалений

Просмотреть файл

@ -324,14 +324,11 @@ max-width: ${width}px; max-height: ${height}px`;
extras
);
} catch (e) {
comparison = { lhs: null, rhs: null, passed: false, error: e, msg: null };
}
if (comparison.msg) {
result.message += `${comparison.msg}\n`;
comparison = { lhs: null, rhs: null, passed: false, error: e };
}
if (comparison.error !== null) {
result.status = STATUS.ERROR;
result.message += String(comparison.error);
result.message = String(comparison.error);
result.stack = comparison.error.stack;
}
@ -415,7 +412,6 @@ max-width: ${width}px; max-height: ${height}px`;
let error = null;
let pixelsDifferent = null;
let maxDifferences = {};
let msg = null;
try {
pixelsDifferent = this.windowUtils.compareCanvases(
@ -437,8 +433,10 @@ max-width: ${width}px; max-height: ${height}px`;
switch (relation) {
case "==":
if (!passed) {
msg = `Found ${pixelsDifferent} pixels different, ` +
logger.info(
`Found ${pixelsDifferent} pixels different, ` +
`maximum difference per channel ${maxDifferences.value}`
);
}
break;
case "!=":
@ -450,7 +448,7 @@ max-width: ${width}px; max-height: ${height}px`;
);
}
}
return { lhs, rhs, passed, error, msg };
return { lhs, rhs, passed, error };
}
isAcceptableDifference(maxDifference, pixelsDifferent, allowed) {