e2e-test: copy yarn patches to dist dir

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
This commit is contained in:
Patrik Oldsberg
2023-09-12 17:39:40 +02:00
parent 52f2416abe
commit f863947ea7
+6
View File
@@ -181,6 +181,12 @@ async function buildDistWorkspace(workspaceName: string, rootDir: string) {
print('Pinning yarn version in workspace');
await pinYarnVersion(workspaceDir);
const yarnPatchesPath = paths.resolveOwnRoot('.yarn/patches');
if (await fs.pathExists(yarnPatchesPath)) {
print('Copying yarn patches');
await fs.copy(yarnPatchesPath, resolvePath(workspaceDir, '.yarn/patches'));
}
print('Installing workspace dependencies');
await runPlain(['yarn', 'workspaces', 'focus', '--all', '--production'], {
cwd: workspaceDir,