Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion dev-packages/browser-integration-tests/utils/staticAssets.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,16 @@ export function addStaticAssetSymlink(localOutPath: string, originalPath: string

// Only copy files once
if (!fs.existsSync(newPath)) {
fs.symlinkSync(originalPath, newPath);
try {
fs.symlinkSync(originalPath, newPath);
} catch (error) {
// There must be some race condition here as some of our tests flakey
// because the file already exists. Let's catch and ignore
// only ignore these kind of errors
if (!`${error}`.includes('file already exists')) {
throw error;
}
}
}

symlinkAsset(newPath, path.join(localOutPath, fileName));
Expand Down