Skip to content

Migrate from Yarn to npm, add unit tests, update dependencies#394

Merged
luispabon merged 3 commits into
masterfrom
more-tests
May 27, 2026
Merged

Migrate from Yarn to npm, add unit tests, update dependencies#394
luispabon merged 3 commits into
masterfrom
more-tests

Conversation

@luispabon
Copy link
Copy Markdown
Contributor

@luispabon luispabon commented May 27, 2026

Summary

Migrate the frontend build tooling from Yarn to npm, replace the Bower-based font-awesome dependency with the direct npm package, add unit tests for several domain classes, and clean up Dockerfile/Makefile.

Changes

Build tooling migration (Yarn → npm)

  • Dockerfile: Replace yarn install with npm ci, yarn build:css with npm run build:css, copy package-lock.json instead of yarn.lock, add WORKDIR /application for correct paths
  • Makefile: Replace yarn-install target with npm-install, update build-css to use npm, update install-dependencies dependency chain
  • package.json: Remove @bower_components/font-awesome dependency, add font-awesome (npm), switch engines from yarn to npm

Dockerfile cleanup

  • Fix asAS (uppercase for consistency)
  • Improve comment wording for clarity
  • Fix asset copy paths to use correct /application/ prefix and copy font-awesome directly instead of the entire @bower_components directory

Dependency updates

  • Pinned dev dependency versions: autoprefixer ^10.5.0, postcss ^8.5.15, postcss-cli ^11.0.1, tailwindcss ^3.4.19
  • Replaced yarn.lock with package-lock.json (npm lockfile v3)

New tests

  • tests/Unit/PHPDocker/Project/ProjectTest.php — Unit tests for the Project model
  • tests/Unit/PHPDocker/Project/ServiceOptions/MemcachedTest.php — Unit tests for Memcached service options
  • tests/Unit/Assert/PostgresTypeValidatorTest.php — Unit tests for PostgresTypeValidator
  • tests/Functional/GeneratorTest.php — Expanded functional test coverage

luispabon added 3 commits May 27, 2026 14:18
… yarn install in Dockerfile/Makefile

- Add ProjectTest covering nginx defaults and elasticsearch enabled state
- Add MemcachedTest covering container suffix, enabled state, and external port
- Add PostgresTypeValidatorTest for custom message on invalid version
- Add functional test for Elasticsearch version in docker-compose
- Fix Dockerfile AS keyword casing for consistency
- Install yarn@1.22.22 explicitly via npm in Dockerfile and Makefile
  to avoid relying on system yarn in node images
@luispabon luispabon changed the title Update npm dependencies Migrate from Yarn to npm, add unit tests, update dependencies May 27, 2026
@luispabon luispabon merged commit 4d1dea8 into master May 27, 2026
1 check passed
@luispabon luispabon deleted the more-tests branch May 27, 2026 13:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant