-
Notifications
You must be signed in to change notification settings - Fork 0
Type assert as removed #78
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
* eliminados as const * eliminados type cast en sectionContext
|
|
✅ Deploy Preview for secorto-astro ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
SeCOrTo web
|
||||||||||||||||||||||||||||
| Project |
SeCOrTo web
|
| Branch Review |
pull/78/head
|
| Run status |
|
| Run duration | 01m 35s |
| Commit |
|
| Committer | Sergio Orozco |
| View all properties for this run ↗︎ | |
| Test results | |
|---|---|
|
|
0
|
|
|
0
|
|
|
0
|
|
|
0
|
|
|
6
|
| View all changes introduced in this branch ↗︎ | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
Este PR simplifica el tipado en la suite de tests (unit y e2e) eliminando type assertions redundantes y apoyándose más en tipos inferidos y en languageKeys como fuente única de locales.
Changes:
- Eliminación de type assertions innecesarios en tests unitarios.
- Reemplazo de arreglos locales hardcodeados (
['es','en'] as const) porlanguageKeysen varios e2e tests. - Simplificación de casts redundantes en callbacks de
evaluate()y en llamadas de helpers tipados.
Reviewed changes
Copilot reviewed 11 out of 11 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| tests/unit/utils/sectionContext.test.ts | Quita casts redundantes al usar helpers que ya retornan tipos explícitos. |
| tests/unit/i18n/utils.test.ts | Simplifica mocks removiendo as const donde no aporta valor en el test. |
| tests/e2e/titles/work.titles.spec.ts | Itera por languageKeys y elimina casts de locale/key al indexar ui. |
| tests/e2e/titles/project.titles.spec.ts | Igual que el anterior para la sección “project”. |
| tests/e2e/titles/community.titles.spec.ts | Igual que el anterior para la sección “community”. |
| tests/e2e/smoke/charla.spec.ts | Usa languageKeys y tipa expected fixtures con UILanguages directamente. |
| tests/e2e/main-page.spec.ts | Elimina casting intermedio y usa languageKeys directamente en el loop. |
| tests/e2e/footer.spec.ts | Reemplaza locales hardcodeados por languageKeys y elimina casts a UILanguages. |
| tests/e2e/color-switch.spec.ts | Elimina cast redundante en getComputedStyle() dentro de evaluate(). |
| tests/e2e/blog.list.spec.ts | Tipado explícito de fixtures y elimina cast redundante al navegar. |
| tests/e2e/a11y/charla.a11y.spec.ts | Usa languageKeys para ejecutar tests a11y por locale sin hardcodear. |

Pull request
Removido type assertions que no agregan mucho valor en los test e2e y en unit