CodeForPhilly / CodeForPhilly/codeforphilly-ng

Make apps/api test fixtures cross-platform (Windows)

Ouverte
#162 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub
Langage dominant
TypeScript
Étoiles
1
Forks
1
Merge moyen
5 j 3 h
PR mergées (30 j)
9

Description

Surfaced while closing out `plans/site-check-153.md` (PR #154).

On a Windows dev box the `apps/api` suite finishes 3 failed | 30 passed files, 10 failed | 413 passed tests, on a tree where `git diff develop..HEAD -- apps/api packages/` is empty. The failures spread across `scrub-data.test.ts` (4), `internal-reload.test.ts` (4), and `store.test.ts` (2), and reproduce with each file run alone, so it is not runner contention. Checking out `develop` and re-running `store.test.ts` reproduces its 2 failures exactly.

Mechanism (at least for `store.test.ts`): the fixture injects a write failure by pointing the private store at `/dev/null/impossible-path` and asserting the transaction rejects. On Windows that is an ordinary creatable directory, so the write succeeds and the expected throw never happens. The other seven likely share a POSIX-ism of the same flavor.

CI runs the gate on Linux where the fixtures behave as intended, so this only blocks the documented local validation gate on Windows. Worth a cross-platform fixture cleanup (e.g. a path that cannot exist on any OS, or a mocked write failure) if Windows dev boxes are to be supported.

Guide de contribution

Aucun guide de contribution indexé pour ce dépôt

Piste de recherche

Start with apps/api tests/scrub-data.test.ts, internal-reload.test.ts, and store.test.ts, then run each file independently on Windows and compare with the develop results. Inspect the fixtures that rely on POSIX-specific paths or write failures. Done means all three files pass on Windows while preserving the existing Linux behavior.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
typescript
Domaine
api, testing
Type d'issue
Bug
Difficulté
3/5
Temps estimé
1-2 jours
Activité
Active
Clarté
Plutôt claire
Accessibilité débutants
78/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.