CRAP: newly scored platform-apple simulator boot retry and macOS helper file listing
I maintainer di solito rispondono entro 1 giorno
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 52/100
- Tipo di issue
- Bug
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- typescript
- Ambito
- mobile-dev, testing-qa
Direzione di ricerca
Start with packages/platform-apple/src/core/simulator.ts and its simulator boot entry point; add coverage for shouldRetry and classifyReason through that public path. Then inspect packages/platform-apple/src/os/macos/helper.ts and test listMacOsHelperSourceFiles through its owning module. Run pnpm check:coverage-crap --all on a branch containing #3448 and finish with pnpm check:affected --run; #3323 also edits the helper file.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Purpose
These findings were exposed by #3448, which patches the coverage tooling (part of #3425) so the six files that used to be unscored now get scores. Re-scoring them (full pnpm test:coverage on #3448's head, then pnpm check:coverage-crap --all) adds three functions at or above CRAP 30.
Findings (head 18d22c745 of #3448)
| Function | CRAP | CC | Coverage |
|---|---|---|---|
packages/platform-apple/src/core/simulator.ts:142 shouldRetry (boot retry policy) |
72 | 8 | 0% |
packages/platform-apple/src/core/simulator.ts:156 classifyReason (boot deadline classifier) |
56 | 7 | 0% |
packages/platform-apple/src/os/macos/helper.ts:190 files (listMacOsHelperSourceFiles entry mapper) |
42 | 6 | 0% |
Owned files
packages/platform-apple/src/core/simulator.tspackages/platform-apple/src/os/macos/helper.ts
Notes
shouldRetry,classifyReasonand thecatchblock each rebuild the sameclassifyBootFailureinput frombootStatusResult?.stdout ?? bootResult?.stdout. One local classifier closure would remove most of that branching, so covering the retry and deadline paths through the simulator boot entry point may need only a small production change.- Open #3323 also edits
os/macos/helper.ts. Add tests only for that file, or rebase onto #3323 first. - These scores depend on #3448's patches. Without them, the two files stay unscored on
main, so measure on a branch that includes #3448 (or after it merges).
Completion
- None of the three functions is listed by
pnpm check:coverage-crap --allon the PR head (with #3448's patches). - Tests go through the owning module's public entry point. No new production exports for tests and no test-only DI.
pnpm check:affected --runpasses on the pushed head.
Part of #3414.
- Lingua principale
- TypeScript
- Stelle
- 4.9k
- Fork
- 328
- Merge medio
- 12h 18m
- PR unite (30g)
- 561
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di callstack/agent-device
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
callstack/agent-device#3407 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 88/100
callstack/agent-device#3353 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
callstack/agent-device#1869 ·
I maintainer di solito rispondono entro 1 giorno
-
needs-triage
Difficoltà 3/5 1-2 giorni Idoneità per principianti 76/100
callstack/agent-device#3453 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 4/5 1-2 giorni Idoneità per principianti 55/100
callstack/agent-device#3449 ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di callstack/agent-device