test(dashboard): reactivate request logger coverage - #13843
diegosouzapw merged 3 commits into
Conversation
# Conflicts: # config/quality/vitest-exclusions.json # vitest.config.ts
The drift this PR unblocks is real — the next-intl mock lost its `useLocale` export in diegosouzapw#7935, so the suite died on `No "useLocale" export is defined`. Restoring it is the actual fix. The dialog assertions were also loosened to `[role="dialog"]`, and that part was not needed: 20 components under src/ render that role, so the selector stops proving this particular modal is the one on screen. Measured — keeping only the `useLocale` fix and restoring a precise selector still passes 6/6. Now asserting `[aria-label="ariaLabel"]`, which is what RequestLoggerDetail.tsx:469 renders (the mock returns the key rather than the translation).
|
Mergeada com um ajuste. O conserto que você identificou é real e é o que destrava a suíte: o mock do next-intl perdeu o export O que mudei: as asserções de diálogo tinham sido afrouxadas para Também resolvi o conflito com a #13844: a base listava os dois arquivos, esta branch removia a exclusão do request-logger e a #13844 removia a do webhook-wizard — o resultado combinado remove as duas. Sobre a preocupação de estabilidade: rodei a suíte completa quatro vezes e ela oscila entre 25 e 70 falhas na mesma árvore, com conjuntos diferentes a cada rodada. Mas nenhum dos quatro arquivos reativados aparece em nenhuma das quatro listas — eles são estáveis. A instabilidade é da base, não do seu trabalho, e é a mesma dívida que a #13204 rastreia. |
9688032
into
diegosouzapw:release/v3.8.51
* test(dashboard): reactivate request logger coverage * test(dashboard): assert the request-logger modal by its own label The drift this PR unblocks is real — the next-intl mock lost its `useLocale` export in diegosouzapw#7935, so the suite died on `No "useLocale" export is defined`. Restoring it is the actual fix. The dialog assertions were also loosened to `[role="dialog"]`, and that part was not needed: 20 components under src/ render that role, so the selector stops proving this particular modal is the one on screen. Measured — keeping only the `useLocale` fix and restoring a precise selector still passes 6/6. Now asserting `[aria-label="ariaLabel"]`, which is what RequestLoggerDetail.tsx:469 renders (the mock returns the key rather than the translation). --------- Co-authored-by: Paco Cartones <pacocartones@users.noreply.github.com> Co-authored-by: diegosouzapw <8016841+diegosouzapw@users.noreply.github.com>
Summary
Related Issues
Validation
npm run lint(focused ESLint and Prettier checks)Focused suite 6/6; Prettier; ESLint; dashboard typecheck adds no errors.
Tests Added Or Updated
tests/unit/ui/request-logger-autorefresh-visibility-3972.test.tsxvitest.config.tsandconfig/quality/vitest-exclusions.json.Coverage Notes
This PR restores previously excluded dashboard coverage; no production file changes.
Reviewer Notes
The test preserves its visibility and autorefresh assertions while using the current locale/dialog contracts.