From ab10c0bb0161f02b2dff491c763e37003fbfc870 Mon Sep 17 00:00:00 2001 From: Keith Cirkel Date: Fri, 3 Nov 2023 11:17:21 +0000 Subject: [PATCH 1/3] change `postinstall` to `pretest` script. --- package.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 0b509e1..02eba77 100644 --- a/package.json +++ b/package.json @@ -27,6 +27,7 @@ "bench": "node bench", "lint": "eslint --ignore-path .gitignore .", "semantic-release": "semantic-release pre && npm publish && semantic-release post", + "pretest": "npx playwright install" "test": "npm run test:node && npm run test:browser", "pretest:browser": "npm run build", "test:browser": "wtr", @@ -36,8 +37,7 @@ "build:lib": "esbuild \"src/*.ts\" --outdir=lib --format=esm", "build:esm-bundle": "esbuild --bundle src/index.ts --outfile=loupe.js --format=esm", "build:cjs-bundle": "esbuild --bundle src/index.ts --outfile=loupe.js --format=cjs", - "upload-coverage": "codecov", - "postinstall": "npx playwright install" + "upload-coverage": "codecov" }, "eslintConfig": { "root": true, From d60daef416e93fc8d8929979eb0be6b5f207db09 Mon Sep 17 00:00:00 2001 From: Keith Cirkel Date: Fri, 3 Nov 2023 11:18:13 +0000 Subject: [PATCH 2/3] comma --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 02eba77..ef6d775 100644 --- a/package.json +++ b/package.json @@ -27,7 +27,7 @@ "bench": "node bench", "lint": "eslint --ignore-path .gitignore .", "semantic-release": "semantic-release pre && npm publish && semantic-release post", - "pretest": "npx playwright install" + "pretest": "npx playwright install", "test": "npm run test:node && npm run test:browser", "pretest:browser": "npm run build", "test:browser": "wtr", From 7f25269311faaa9fc2643bc18aa1f3614fa4b9d0 Mon Sep 17 00:00:00 2001 From: Keith Cirkel Date: Fri, 3 Nov 2023 12:52:24 +0000 Subject: [PATCH 3/3] move playright install to pretest:browser --- package.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/package.json b/package.json index ef6d775..ed85244 100644 --- a/package.json +++ b/package.json @@ -27,9 +27,8 @@ "bench": "node bench", "lint": "eslint --ignore-path .gitignore .", "semantic-release": "semantic-release pre && npm publish && semantic-release post", - "pretest": "npx playwright install", "test": "npm run test:node && npm run test:browser", - "pretest:browser": "npm run build", + "pretest:browser": "npx playwright install && npm run build", "test:browser": "wtr", "pretest:node": "npm run build", "test:node": "mocha",