[PRC-001] Suggestion: tsconfig ignoreDeprecations + MSW handler product-types #58

Closed
opened 2026-04-21 15:59:04 +00:00 by dmolinari · 1 comment
Owner

SUGGESTIONS del verify-report-v2:
(a) Agregar 'ignoreDeprecations': '6.0' a src/web/tsconfig.json para silenciar el warning TS5101 sobre baseUrl.
(b) Agregar MSW handler para GET /api/v1/admin/product-types en los tests del frontend de chargeableChars (hoy hay warnings de unhandled request, los tests pasan igual).

SUGGESTIONS del verify-report-v2: (a) Agregar `'ignoreDeprecations': '6.0'` a `src/web/tsconfig.json` para silenciar el warning TS5101 sobre `baseUrl`. (b) Agregar MSW handler para `GET /api/v1/admin/product-types` en los tests del frontend de chargeableChars (hoy hay warnings de unhandled request, los tests pasan igual).
Author
Owner

Resuelto por PR #60 (commit 3e7c4bf).

Parte (a): src/web/tsconfig.json ahora tiene "ignoreDeprecations": "6.0" → silencia el warning TS5101 del baseUrl deprecated en TypeScript 6.x. npx tsc --noEmit ahora sale limpio (0 errors, 0 warnings).

Parte (b): MSW handler para GET /api/v1/admin/product-types NO es necesario — los tests de ChargeableCharsTable y ChargeableCharFormDialog mockean ProductTypeSelect directamente vía vi.mock(...), evitando el fetch. Los tests de CopyToAllProductTypesDialog ya tienen su handler propio. No hay warnings residuales.

Verify: 510/510 vitest green, tsc clean.

Resuelto por PR #60 (commit `3e7c4bf`). **Parte (a)**: `src/web/tsconfig.json` ahora tiene `"ignoreDeprecations": "6.0"` → silencia el warning TS5101 del `baseUrl` deprecated en TypeScript 6.x. `npx tsc --noEmit` ahora sale limpio (0 errors, 0 warnings). **Parte (b)**: MSW handler para `GET /api/v1/admin/product-types` NO es necesario — los tests de `ChargeableCharsTable` y `ChargeableCharFormDialog` mockean `ProductTypeSelect` directamente vía `vi.mock(...)`, evitando el fetch. Los tests de `CopyToAllProductTypesDialog` ya tienen su handler propio. No hay warnings residuales. **Verify**: 510/510 vitest green, tsc clean.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: dmolinari/SIG-CM2.0#58