From 89bd541247c27eb2ffdd8577a573d83f2961a971 Mon Sep 17 00:00:00 2001 From: Peter BALIVET Date: Tue, 1 Jul 2025 13:55:33 +0200 Subject: [PATCH] Added frontend + backend tests --- Dockerfile | 2 +- client/components/cards/LazyBookCard.vue | 4 +- client/cypress.config.js | 8 +- .../tests/components/cards/LazyBookCard.cy.js | 7 +- .../tests/components/ui/RatingInput.cy.js | 88 + client/package-lock.json | 14473 +++++++++++----- client/package.json | 15 +- client/plugins/init.client.js | 72 +- client/vite.config.js | 12 + package-lock.json | 13 +- package.json | 3 +- server/controllers/LibraryItemController.js | 105 +- server/migrations/v2.25.2-add-book-ratings.js | 237 +- .../controllers/LibraryItemController.test.js | 213 +- .../v2.25.2-add-book-ratings.test.js | 132 + 15 files changed, 10887 insertions(+), 4497 deletions(-) create mode 100644 client/cypress/tests/components/ui/RatingInput.cy.js create mode 100644 client/vite.config.js create mode 100644 test/server/migrations/v2.25.2-add-book-ratings.test.js diff --git a/Dockerfile b/Dockerfile index 816bdd3c3..ae08c823d 100644 --- a/Dockerfile +++ b/Dockerfile @@ -6,7 +6,7 @@ FROM node:20-alpine AS build-client WORKDIR /client COPY /client /client -RUN npm ci && npm cache clean --force +RUN npm install && npm cache clean --force RUN npm run generate ### STAGE 1: Build server ### diff --git a/client/components/cards/LazyBookCard.vue b/client/components/cards/LazyBookCard.vue index 35c959fad..cff417554 100644 --- a/client/components/cards/LazyBookCard.vue +++ b/client/components/cards/LazyBookCard.vue @@ -78,7 +78,7 @@ - +
priority_high
@@ -136,7 +136,7 @@