Commit 34d60e4
feat(cli): auto-include pnpm patches directory in Playwright bundles (#1273)
* feat(cli): auto-include pnpm patches directory in Playwright bundles
When using pnpm, the CLI now automatically includes the `patches/` directory
in Playwright check bundles if it exists, preventing `pnpm install` failures
at runtime when patched dependencies are referenced in the lockfile.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: resolve require-await lint error in test mock
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* refactor: use async fs operations in getAutoIncludes tests
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* refactor: remove unnecessary patches dir existence check from getAutoIncludes
The glob pattern harmlessly matches nothing when the directory doesn't
exist, so the statSync check was redundant. This also removes the
basePath parameter and simplifies the tests to pure logic checks.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* refactor: narrow auto-include pattern to patches/*.patch
More precise than patches/** — only includes actual patch files,
avoiding accidentally bundling unrelated files in the directory.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* fix: resolve include patterns to absolute paths in getAutoIncludes
Prevents adding duplicate patches include when the user specifies
the pattern with a relative prefix (./patches/**) or absolute path.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* fix: use platform-appropriate paths in getAutoIncludes tests
path.resolve ensures basePath is valid on Windows where /project
is not treated as an absolute path.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: Simo Kinnunen <simo@checklyhq.com>1 parent f9d203f commit 34d60e4
2 files changed
+74
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| 8 | + | |
8 | 9 | | |
| 10 | + | |
9 | 11 | | |
10 | 12 | | |
11 | 13 | | |
| |||
29 | 31 | | |
30 | 32 | | |
31 | 33 | | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
32 | 82 | | |
33 | 83 | | |
34 | 84 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
15 | | - | |
| 15 | + | |
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| |||
143 | 143 | | |
144 | 144 | | |
145 | 145 | | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
146 | 165 | | |
147 | 166 | | |
148 | 167 | | |
| |||
195 | 214 | | |
196 | 215 | | |
197 | 216 | | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
198 | 220 | | |
199 | 221 | | |
200 | 222 | | |
201 | | - | |
| 223 | + | |
202 | 224 | | |
203 | 225 | | |
204 | 226 | | |
| |||
0 commit comments