From a843c4d76068af569099f58490278739ee42185e Mon Sep 17 00:00:00 2001 From: Norbert de Langen Date: Fri, 9 Jun 2023 10:31:21 +0200 Subject: [PATCH 1/2] force add playwright packages --- scripts/utils/yarn.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/scripts/utils/yarn.ts b/scripts/utils/yarn.ts index c7022c88755b..0ea4de7597a0 100644 --- a/scripts/utils/yarn.ts +++ b/scripts/utils/yarn.ts @@ -20,10 +20,18 @@ export const addPackageResolutions = async ({ cwd, dryRun }: YarnOptions) => { const packageJsonPath = path.join(cwd, 'package.json'); const packageJson = await readJSON(packageJsonPath); + packageJson.devDependencies = { + ...packageJson.devDependencies, + playwright: '^1.35.0', + 'playwright-core': '^1.35.0', + '@playwright/test': '^1.35.0', + }; packageJson.resolutions = { ...storybookVersions, 'enhanced-resolve': '~5.10.0', // TODO, remove this // this is for our CI test, ensure we use the same version as docker image, it should match version specified in `./code/package.json` and `.circleci/config.yml` + playwright: '^1.35.0', + 'playwright-core': '^1.35.0', '@playwright/test': '^1.35.0', }; await writeJSON(packageJsonPath, packageJson, { spaces: 2 }); From ab6caf57492df7f8207e312f05543d969926fab7 Mon Sep 17 00:00:00 2001 From: Norbert de Langen Date: Fri, 9 Jun 2023 11:44:06 +0200 Subject: [PATCH 2/2] remove the 2 dependencies, but keep the resolution --- code/package.json | 2 -- code/yarn.lock | 2 -- scripts/utils/yarn.ts | 6 ------ 3 files changed, 10 deletions(-) diff --git a/code/package.json b/code/package.json index 725a4333c133..8f34d5ae3d53 100644 --- a/code/package.json +++ b/code/package.json @@ -246,8 +246,6 @@ "node-gyp": "^9.3.1", "nx": "16.2.1", "nx-cloud": "16.0.5", - "playwright": "^1.35.0", - "playwright-core": "^1.35.0", "prettier": "2.8.0", "process": "^0.11.10", "raf": "^3.4.1", diff --git a/code/yarn.lock b/code/yarn.lock index 42040001bf2c..4fdacfef8fb7 100644 --- a/code/yarn.lock +++ b/code/yarn.lock @@ -7210,8 +7210,6 @@ __metadata: node-gyp: ^9.3.1 nx: 16.2.1 nx-cloud: 16.0.5 - playwright: ^1.35.0 - playwright-core: ^1.35.0 prettier: 2.8.0 process: ^0.11.10 raf: ^3.4.1 diff --git a/scripts/utils/yarn.ts b/scripts/utils/yarn.ts index 0ea4de7597a0..9cdeff5b835c 100644 --- a/scripts/utils/yarn.ts +++ b/scripts/utils/yarn.ts @@ -20,12 +20,6 @@ export const addPackageResolutions = async ({ cwd, dryRun }: YarnOptions) => { const packageJsonPath = path.join(cwd, 'package.json'); const packageJson = await readJSON(packageJsonPath); - packageJson.devDependencies = { - ...packageJson.devDependencies, - playwright: '^1.35.0', - 'playwright-core': '^1.35.0', - '@playwright/test': '^1.35.0', - }; packageJson.resolutions = { ...storybookVersions, 'enhanced-resolve': '~5.10.0', // TODO, remove this