Commit decb3bd
refactor(@angular/build): optimize Vitest in-memory plugin resolveId
Refactors the `resolveId` hook in the `angular:test-in-memory-provider`
Vite plugin to improve clarity, efficiency, and cross-platform consistency.
Key improvements include:
- Consolidating path resolution logic into a single flow.
- Ensuring all resolved paths are absolute and consistently POSIX-formatted.
- Prioritizing direct test entry point lookups.
- Removing redundant checks and assertions.
(cherry picked from commit dd99abc)1 parent 1737ce2 commit decb3bd
File tree
1 file changed
+21
-17
lines changed- packages/angular/build/src/builders/unit-test/runners/vitest
1 file changed
+21
-17
lines changedLines changed: 21 additions & 17 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
171 | 171 | | |
172 | 172 | | |
173 | 173 | | |
174 | | - | |
175 | | - | |
176 | | - | |
177 | | - | |
178 | | - | |
179 | | - | |
180 | | - | |
181 | | - | |
182 | | - | |
183 | | - | |
184 | | - | |
185 | | - | |
186 | | - | |
187 | | - | |
| 174 | + | |
188 | 175 | | |
189 | 176 | | |
190 | 177 | | |
191 | 178 | | |
192 | | - | |
193 | | - | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
194 | 195 | | |
195 | | - | |
| 196 | + | |
196 | 197 | | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
197 | 201 | | |
198 | 202 | | |
199 | 203 | | |
| |||
0 commit comments