Quellcode durchsuchen

fix(ci): add playwright dependency and test:browser:install script

Install playwright so pnpm resolves the CLI in Actions. Run
browser install via test:browser:install instead of pnpm exec.
satnaing vor 2 Monaten
Ursprung
Commit
34e616d16a
3 geänderte Dateien mit 8 neuen und 3 gelöschten Zeilen
  1. 2 2
      .github/workflows/ci.yml
  2. 3 1
      package.json
  3. 3 0
      pnpm-lock.yaml

+ 2 - 2
.github/workflows/ci.yml

@@ -37,8 +37,8 @@ jobs:
       - name: Run Prettier check
         run: pnpm format:check
 
-      - name: Install Playwright Chromium
-        run: pnpm exec playwright install chromium --with-deps
+      - name: Install browsers
+        run: pnpm test:browser:install
 
       - name: Run tests
         run: pnpm test

+ 3 - 1
package.json

@@ -15,7 +15,8 @@
     "test:watch": "vitest --browser.headless",
     "test:ui": "vitest --ui --browser.headless",
     "test:browser": "vitest",
-    "test:coverage": "vitest run --coverage --browser.headless"
+    "test:coverage": "vitest run --coverage --browser.headless",
+    "test:browser:install": "playwright install chromium --with-deps"
   },
   "dependencies": {
     "@clerk/clerk-react": "^5.61.3",
@@ -82,6 +83,7 @@
     "eslint-plugin-react-refresh": "^0.5.2",
     "globals": "^17.5.0",
     "knip": "^6.4.1",
+    "playwright": "1.59.1",
     "prettier": "^3.8.3",
     "prettier-plugin-tailwindcss": "^0.7.2",
     "typescript": "~6.0.3",

+ 3 - 0
pnpm-lock.yaml

@@ -195,6 +195,9 @@ importers:
       knip:
         specifier: ^6.4.1
         version: 6.4.1
+      playwright:
+        specifier: 1.59.1
+        version: 1.59.1
       prettier:
         specifier: ^3.8.3
         version: 3.8.3