diff options
author | dizzy <diosmosis@users.noreply.github.com> | 2022-05-27 03:01:45 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-27 03:01:45 +0300 |
commit | 229c9c4ec4dce7dc96e4599e0ae7320005fcfb46 (patch) | |
tree | e069942f7fac2599921f5dd49b81c50235039941 /tests | |
parent | 1b964c6ba971121fa18730165c664391a9ff3db5 (diff) |
ignore linkSync errors in custom chai assertion to avoid error in Funnels build (#19264)
Diffstat (limited to 'tests')
-rw-r--r-- | tests/lib/screenshot-testing/support/chai-extras.js | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/lib/screenshot-testing/support/chai-extras.js b/tests/lib/screenshot-testing/support/chai-extras.js index 2160673845..80871f7342 100644 --- a/tests/lib/screenshot-testing/support/chai-extras.js +++ b/tests/lib/screenshot-testing/support/chai-extras.js @@ -92,7 +92,11 @@ module.exports = function makeChaiImageAssert(comparisonCommand = 'compare') { // copy to diff dir for ui tests viewer (we don't generate diffs w/ compare since it slows the tests a bit) if (!fs.existsSync(diffPath)) { - fs.linkSync(expectedPath, diffPath); + try { + fs.linkSync(expectedPath, diffPath); + } catch (e) { + console.log(`Failed to copy ${expectedPath} to ${diffPath}`); + } } } |