feat: add CI pipeline to run tests on PRs - #5
Merged
Merged
Conversation
added 6 commits
April 25, 2026 21:12
- Crear workflow .github/workflows/test-on-pr.yml - Trigger: pull_request sobre branches develop y main - Runner: ubuntu-latest con timeout de 10 minutos - Steps: checkout, setup-node v16, npm ci, npm test (CI=true) - Cache de npm habilitado para acelerar ejecuciones subsiguientes - Agregar especificación, plan y tareas de la feature Refs: specs/003-ci-test-pr
…ndencies babel-preset-react-app (part of the unmaintained create-react-app) uses this plugin without declaring it as a dependency. Adding it explicitly to devDependencies prevents a potential breakage and silences the startup warning.
ntolosa
added a commit
that referenced
this pull request
May 3, 2026
* draft version of matrix render * Feature/ficha rendering (#2) * draft version for item movement * adding logic to move ficha * adding logic to manually move an item --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * adding logic to flip ficha * adding logic to check coalitions * adding logic to remove completed lines * adding logic to display next item * adding some basic styles * adding logic to down key * bug fixing: fixing flip issue * adding some styles in controls * adding ficha colors * adding logic to finish game * adding unit test * fix: resolve matrix height reduction bug on multiple line clearing * Fix timer reset on piece movement by preventing stale closures * feat(pause): implementar pausa del juego con tecla P/Escape y botón (#3) * [Spec Kit] Add specification, implementation plan, and tasks for game-pause feature * feat(pause): implementar pausa del juego con tecla P/Escape y botón - Agregar estado isPaused y callback togglePause al componente Tetris - Detener gravedad (setInterval) cuando el juego está pausado - Bloquear inputs de teclado y botones durante la pausa - Ocultar contenido del tablero manteniendo el contorno visible - Mostrar overlay 'Pausado' centrado sobre el tablero - Ocultar preview de la siguiente ficha durante la pausa - Agregar botón Pausa/Reanudar con label dinámico - Agregar estilos para overlay y botón de pausa - Agregar tests para renderizado y comportamiento del botón - Actualizar .gitignore con patrones estándar de Node.js/CRA Closes: US1 (pausar), US2 (reanudar), US3 (feedback visual) Tasks: T001-T017 completadas --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * feat: add CI pipeline to run tests on PRs (#5) * ci: agregar GitHub Actions workflow para ejecutar tests en PRs - Crear workflow .github/workflows/test-on-pr.yml - Trigger: pull_request sobre branches develop y main - Runner: ubuntu-latest con timeout de 10 minutos - Steps: checkout, setup-node v16, npm ci, npm test (CI=true) - Cache de npm habilitado para acelerar ejecuciones subsiguientes - Agregar especificación, plan y tareas de la feature Refs: specs/003-ci-test-pr * fix: add @babel/plugin-proposal-private-property-in-object to devDependencies babel-preset-react-app (part of the unmaintained create-react-app) uses this plugin without declaring it as a dependency. Adding it explicitly to devDependencies prevents a potential breakage and silences the startup warning. * test: remove obsolete App.test.js * ci: enforce 80% test coverage threshold * test: add tests and fix bugs to increase test coverage above 80% * fix: revert extra bounds checks to restore branch coverage >80% --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * feat(game-start): implementar inicio explícito del juego con botón Iniciar (#4) * feat(game-start): implementar inicio explícito del juego con botón Iniciar - Reemplazar isEndGame/isPaused por variable única gameStatus ('idle'|'playing'|'paused'|'gameover') - Diferir generación de piezas al momento de iniciar (startGame callback) - Agregar botón 'Iniciar' visible solo en estado idle - Ocultar controles del juego (mover, rotar, drop, pausa) hasta que el juego inicie - Ocultar preview de siguiente ficha en estado idle - Agregar transición automática game over → idle (con overlay 'Game Over') - Agregar estilos para botón de inicio (.controls__start) - Actualizar tests para cubrir estado idle, inicio y controles - Agregar especificación, plan de implementación y tareas Closes: US1 (iniciar juego), US2 (feedback visual idle), US3 (reinicio post game over) Tasks: T001-T027 completadas * fix(test): resolve infinite loop and unhandled mock exceptions in test suite - Refactor changePosition to prevent calling setGameStatus inside state updater - Initialize missing start game sequences in spec files to prevent query crash - Force Math.random mock to return stable value to avoid random layout crashes --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * feat: Add GitHub Pages deployment workflow (#6) Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local>
ntolosa
added a commit
that referenced
this pull request
May 3, 2026
* draft version of matrix render * Feature/ficha rendering (#2) * draft version for item movement * adding logic to move ficha * adding logic to manually move an item --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * adding logic to flip ficha * adding logic to check coalitions * adding logic to remove completed lines * adding logic to display next item * adding some basic styles * adding logic to down key * bug fixing: fixing flip issue * adding some styles in controls * adding ficha colors * adding logic to finish game * adding unit test * fix: resolve matrix height reduction bug on multiple line clearing * Fix timer reset on piece movement by preventing stale closures * feat(pause): implementar pausa del juego con tecla P/Escape y botón (#3) * [Spec Kit] Add specification, implementation plan, and tasks for game-pause feature * feat(pause): implementar pausa del juego con tecla P/Escape y botón - Agregar estado isPaused y callback togglePause al componente Tetris - Detener gravedad (setInterval) cuando el juego está pausado - Bloquear inputs de teclado y botones durante la pausa - Ocultar contenido del tablero manteniendo el contorno visible - Mostrar overlay 'Pausado' centrado sobre el tablero - Ocultar preview de la siguiente ficha durante la pausa - Agregar botón Pausa/Reanudar con label dinámico - Agregar estilos para overlay y botón de pausa - Agregar tests para renderizado y comportamiento del botón - Actualizar .gitignore con patrones estándar de Node.js/CRA Closes: US1 (pausar), US2 (reanudar), US3 (feedback visual) Tasks: T001-T017 completadas --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * feat: add CI pipeline to run tests on PRs (#5) * ci: agregar GitHub Actions workflow para ejecutar tests en PRs - Crear workflow .github/workflows/test-on-pr.yml - Trigger: pull_request sobre branches develop y main - Runner: ubuntu-latest con timeout de 10 minutos - Steps: checkout, setup-node v16, npm ci, npm test (CI=true) - Cache de npm habilitado para acelerar ejecuciones subsiguientes - Agregar especificación, plan y tareas de la feature Refs: specs/003-ci-test-pr * fix: add @babel/plugin-proposal-private-property-in-object to devDependencies babel-preset-react-app (part of the unmaintained create-react-app) uses this plugin without declaring it as a dependency. Adding it explicitly to devDependencies prevents a potential breakage and silences the startup warning. * test: remove obsolete App.test.js * ci: enforce 80% test coverage threshold * test: add tests and fix bugs to increase test coverage above 80% * fix: revert extra bounds checks to restore branch coverage >80% --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * feat(game-start): implementar inicio explícito del juego con botón Iniciar (#4) * feat(game-start): implementar inicio explícito del juego con botón Iniciar - Reemplazar isEndGame/isPaused por variable única gameStatus ('idle'|'playing'|'paused'|'gameover') - Diferir generación de piezas al momento de iniciar (startGame callback) - Agregar botón 'Iniciar' visible solo en estado idle - Ocultar controles del juego (mover, rotar, drop, pausa) hasta que el juego inicie - Ocultar preview de siguiente ficha en estado idle - Agregar transición automática game over → idle (con overlay 'Game Over') - Agregar estilos para botón de inicio (.controls__start) - Actualizar tests para cubrir estado idle, inicio y controles - Agregar especificación, plan de implementación y tareas Closes: US1 (iniciar juego), US2 (feedback visual idle), US3 (reinicio post game over) Tasks: T001-T027 completadas * fix(test): resolve infinite loop and unhandled mock exceptions in test suite - Refactor changePosition to prevent calling setGameStatus inside state updater - Initialize missing start game sequences in spec files to prevent query crash - Force Math.random mock to return stable value to avoid random layout crashes --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * feat: Add GitHub Pages deployment workflow (#6) Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * fix branch name on yaml config (#8) Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local>
ntolosa
added a commit
that referenced
this pull request
May 3, 2026
* draft version of matrix render * Feature/ficha rendering (#2) * draft version for item movement * adding logic to move ficha * adding logic to manually move an item --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * adding logic to flip ficha * adding logic to check coalitions * adding logic to remove completed lines * adding logic to display next item * adding some basic styles * adding logic to down key * bug fixing: fixing flip issue * adding some styles in controls * adding ficha colors * adding logic to finish game * adding unit test * fix: resolve matrix height reduction bug on multiple line clearing * Fix timer reset on piece movement by preventing stale closures * feat(pause): implementar pausa del juego con tecla P/Escape y botón (#3) * [Spec Kit] Add specification, implementation plan, and tasks for game-pause feature * feat(pause): implementar pausa del juego con tecla P/Escape y botón - Agregar estado isPaused y callback togglePause al componente Tetris - Detener gravedad (setInterval) cuando el juego está pausado - Bloquear inputs de teclado y botones durante la pausa - Ocultar contenido del tablero manteniendo el contorno visible - Mostrar overlay 'Pausado' centrado sobre el tablero - Ocultar preview de la siguiente ficha durante la pausa - Agregar botón Pausa/Reanudar con label dinámico - Agregar estilos para overlay y botón de pausa - Agregar tests para renderizado y comportamiento del botón - Actualizar .gitignore con patrones estándar de Node.js/CRA Closes: US1 (pausar), US2 (reanudar), US3 (feedback visual) Tasks: T001-T017 completadas --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * feat: add CI pipeline to run tests on PRs (#5) * ci: agregar GitHub Actions workflow para ejecutar tests en PRs - Crear workflow .github/workflows/test-on-pr.yml - Trigger: pull_request sobre branches develop y main - Runner: ubuntu-latest con timeout de 10 minutos - Steps: checkout, setup-node v16, npm ci, npm test (CI=true) - Cache de npm habilitado para acelerar ejecuciones subsiguientes - Agregar especificación, plan y tareas de la feature Refs: specs/003-ci-test-pr * fix: add @babel/plugin-proposal-private-property-in-object to devDependencies babel-preset-react-app (part of the unmaintained create-react-app) uses this plugin without declaring it as a dependency. Adding it explicitly to devDependencies prevents a potential breakage and silences the startup warning. * test: remove obsolete App.test.js * ci: enforce 80% test coverage threshold * test: add tests and fix bugs to increase test coverage above 80% * fix: revert extra bounds checks to restore branch coverage >80% --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * feat(game-start): implementar inicio explícito del juego con botón Iniciar (#4) * feat(game-start): implementar inicio explícito del juego con botón Iniciar - Reemplazar isEndGame/isPaused por variable única gameStatus ('idle'|'playing'|'paused'|'gameover') - Diferir generación de piezas al momento de iniciar (startGame callback) - Agregar botón 'Iniciar' visible solo en estado idle - Ocultar controles del juego (mover, rotar, drop, pausa) hasta que el juego inicie - Ocultar preview de siguiente ficha en estado idle - Agregar transición automática game over → idle (con overlay 'Game Over') - Agregar estilos para botón de inicio (.controls__start) - Actualizar tests para cubrir estado idle, inicio y controles - Agregar especificación, plan de implementación y tareas Closes: US1 (iniciar juego), US2 (feedback visual idle), US3 (reinicio post game over) Tasks: T001-T027 completadas * fix(test): resolve infinite loop and unhandled mock exceptions in test suite - Refactor changePosition to prevent calling setGameStatus inside state updater - Initialize missing start game sequences in spec files to prevent query crash - Force Math.random mock to return stable value to avoid random layout crashes --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * feat: Add GitHub Pages deployment workflow (#6) Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * fix branch name on yaml config (#8) Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * adding homepage (#10) Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local>
ntolosa
added a commit
that referenced
this pull request
May 24, 2026
* draft version of matrix render * Feature/ficha rendering (#2) * draft version for item movement * adding logic to move ficha * adding logic to manually move an item --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * adding logic to flip ficha * adding logic to check coalitions * adding logic to remove completed lines * adding logic to display next item * adding some basic styles * adding logic to down key * bug fixing: fixing flip issue * adding some styles in controls * adding ficha colors * adding logic to finish game * adding unit test * fix: resolve matrix height reduction bug on multiple line clearing * Fix timer reset on piece movement by preventing stale closures * feat(pause): implementar pausa del juego con tecla P/Escape y botón (#3) * [Spec Kit] Add specification, implementation plan, and tasks for game-pause feature * feat(pause): implementar pausa del juego con tecla P/Escape y botón - Agregar estado isPaused y callback togglePause al componente Tetris - Detener gravedad (setInterval) cuando el juego está pausado - Bloquear inputs de teclado y botones durante la pausa - Ocultar contenido del tablero manteniendo el contorno visible - Mostrar overlay 'Pausado' centrado sobre el tablero - Ocultar preview de la siguiente ficha durante la pausa - Agregar botón Pausa/Reanudar con label dinámico - Agregar estilos para overlay y botón de pausa - Agregar tests para renderizado y comportamiento del botón - Actualizar .gitignore con patrones estándar de Node.js/CRA Closes: US1 (pausar), US2 (reanudar), US3 (feedback visual) Tasks: T001-T017 completadas --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * feat: add CI pipeline to run tests on PRs (#5) * ci: agregar GitHub Actions workflow para ejecutar tests en PRs - Crear workflow .github/workflows/test-on-pr.yml - Trigger: pull_request sobre branches develop y main - Runner: ubuntu-latest con timeout de 10 minutos - Steps: checkout, setup-node v16, npm ci, npm test (CI=true) - Cache de npm habilitado para acelerar ejecuciones subsiguientes - Agregar especificación, plan y tareas de la feature Refs: specs/003-ci-test-pr * fix: add @babel/plugin-proposal-private-property-in-object to devDependencies babel-preset-react-app (part of the unmaintained create-react-app) uses this plugin without declaring it as a dependency. Adding it explicitly to devDependencies prevents a potential breakage and silences the startup warning. * test: remove obsolete App.test.js * ci: enforce 80% test coverage threshold * test: add tests and fix bugs to increase test coverage above 80% * fix: revert extra bounds checks to restore branch coverage >80% --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * feat(game-start): implementar inicio explícito del juego con botón Iniciar (#4) * feat(game-start): implementar inicio explícito del juego con botón Iniciar - Reemplazar isEndGame/isPaused por variable única gameStatus ('idle'|'playing'|'paused'|'gameover') - Diferir generación de piezas al momento de iniciar (startGame callback) - Agregar botón 'Iniciar' visible solo en estado idle - Ocultar controles del juego (mover, rotar, drop, pausa) hasta que el juego inicie - Ocultar preview de siguiente ficha en estado idle - Agregar transición automática game over → idle (con overlay 'Game Over') - Agregar estilos para botón de inicio (.controls__start) - Actualizar tests para cubrir estado idle, inicio y controles - Agregar especificación, plan de implementación y tareas Closes: US1 (iniciar juego), US2 (feedback visual idle), US3 (reinicio post game over) Tasks: T001-T027 completadas * fix(test): resolve infinite loop and unhandled mock exceptions in test suite - Refactor changePosition to prevent calling setGameStatus inside state updater - Initialize missing start game sequences in spec files to prevent query crash - Force Math.random mock to return stable value to avoid random layout crashes --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * feat: Add GitHub Pages deployment workflow (#6) Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * fix branch name on yaml config (#8) Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * adding homepage (#10) Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> * feat(gameplay): implement wall kick rotation mechanics (#12) - Add simplified wall kick offsets algorithm to flipFicha - Ensure rotation works when piece is near bounds - Ensure rotation gracefully fails in confined spaces without crashing - Update checkCoalition usage to check against the temporarily rotated piece - Add unit tests for wall kick rotation and failure scenarios - Satisfy specs/005-wall-kick-rotation requirements Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local> --------- Co-authored-by: Nicolas Tolosa <ntolosa@MacBook-Pro-de-Nicolas.local>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR adds a GitHub Actions workflow that automatically runs the test suite on every pull request targeting
developormain.Changes
.github/workflows/test-on-pr.yml— New workflow: installs dependencies and runsnpm teston PR events.package.json/package-lock.json— Added@babel/plugin-proposal-private-property-in-objectas adevDependencyto fix a missing peer dependency warning frombabel-preset-react-app(create-react-app is unmaintained and the bug will never be fixed upstream).How it works
pull_requestevents targetingdevelopormain.npm ci.npm test -- --watchAll=false.