From ee3a4b421dc5d87872feb190d416b6eb0873e5c8 Mon Sep 17 00:00:00 2001 From: Nicolas Polizzo Date: Wed, 28 Aug 2024 09:54:49 +0200 Subject: [PATCH] try to run lerna from npm scripts --- .github/workflows/ci.yml | 4 ++-- lerna.json | 2 +- package.json | 2 ++ 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b23f1e4b..239af96a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -54,9 +54,9 @@ jobs: run: npm run test:integration - name: Execute tests against Mongoose 7 - run: lerna add mongoose@7 --dev --scope moleculer-db-adapter-mongoose && jest --testMatch "**/moleculer-db-adapter-mongoose/**/*.spec.js" + run: npm run test:mongoose7 if: ${{ matrix.node-version != '10.x' && matrix.node-version != '12.x' }} - name: Execute tests against Mongoose 8 - run: lerna add mongoose@8 --dev --scope moleculer-db-adapter-mongoose && jest --testMatch "**/moleculer-db-adapter-mongoose/**/*.spec.js" + run: npm run test:mongoose8 if: ${{ matrix.node-version != '10.x' && matrix.node-version != '12.x' }} diff --git a/lerna.json b/lerna.json index 0b051fa9..66b12873 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,5 @@ { - "lerna": "2.0.0-rc.5", + "lerna": "4.0.0", "packages": [ "packages/*" ], diff --git a/package.json b/package.json index cd88a30a..e4613b38 100644 --- a/package.json +++ b/package.json @@ -10,6 +10,8 @@ "demo": "node dev.js", "test:unit": "jest --testMatch \"**/unit/**/*.spec.js\" --coverage", "test:integration": "jest --testMatch \"**/integration/**/*.spec.js\" --runInBand --coverage", + "test:mongoose7": "lerna add mongoose@7 --dev --scope moleculer-db-adapter-mongoose && jest --testMatch \"**/moleculer-db-adapter-mongoose/**/*.spec.js", + "test:mongoose8": "lerna add mongoose@8 --dev --scope moleculer-db-adapter-mongoose && jest --testMatch \"**/moleculer-db-adapter-mongoose/**/*.spec.js", "ci": "jest --watch", "coverall": "cat ./coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js", "init": "cd packages && moleculer init addon",