Skip to content

Commit 69b08df

Browse files
justin808claude
andcommitted
Fix CI failures for Playwright E2E tests
- Update knip.ts to ignore Playwright support files (generated by cypress-on-rails gem) - Fix GitHub Actions workflow to install root dependencies first - This resolves the "tsc not found" error during spec/dummy yarn install - The dummy app's preinstall script requires root workspace dependencies to build packages These fixes address the CI failures from knip unused exports and yarn build errors. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
1 parent 2907337 commit 69b08df

File tree

2 files changed

+15
-7
lines changed

2 files changed

+15
-7
lines changed

.github/workflows/playwright.yml

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,6 @@ on:
88
jobs:
99
playwright:
1010
runs-on: ubuntu-latest
11-
defaults:
12-
run:
13-
working-directory: spec/dummy
1411

1512
steps:
1613
- uses: actions/checkout@v4
@@ -19,23 +16,27 @@ jobs:
1916
with:
2017
ruby-version: '3.3'
2118
bundler-cache: true
22-
working-directory: spec/dummy
2319

2420
- uses: actions/setup-node@v4
2521
with:
2622
node-version: '20'
2723
cache: 'yarn'
28-
cache-dependency-path: spec/dummy/yarn.lock
2924

30-
- name: Install dependencies
25+
- name: Install root dependencies
26+
run: yarn install
27+
28+
- name: Install dummy app dependencies
29+
working-directory: spec/dummy
3130
run: |
3231
bundle install
3332
yarn install
3433
3534
- name: Install Playwright browsers
35+
working-directory: spec/dummy
3636
run: yarn playwright install --with-deps
3737

3838
- name: Run Playwright tests
39+
working-directory: spec/dummy
3940
run: yarn playwright test
4041

4142
- uses: actions/upload-artifact@v4

knip.ts

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,8 +102,15 @@ const config: KnipConfig = {
102102
'config/webpack/webpack.config.js',
103103
// SWC configuration for Shakapacker
104104
'config/swc.config.js',
105+
// Playwright E2E test configuration and tests
106+
'e2e/playwright.config.js',
107+
'e2e/playwright/e2e/**/*.spec.js',
108+
],
109+
ignore: [
110+
'**/app-react16/**/*',
111+
// Playwright support files and helpers - generated by cypress-on-rails gem
112+
'e2e/playwright/support/**',
105113
],
106-
ignore: ['**/app-react16/**/*'],
107114
project: ['**/*.{js,cjs,mjs,jsx,ts,cts,mts,tsx}!', 'config/webpack/*.js'],
108115
paths: {
109116
'Assets/*': ['client/app/assets/*'],

0 commit comments

Comments
 (0)