Is the package not using cache properly in our ci runs ? #688
-
Hi ! I've been noticing that our ci has been really slow due to a mongodb download happening despite it being seemingly found in the cache folder
our
is somethign wrong with the way it is currently set up ? |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 2 replies
-
weird that it does not use the downloaded binary but needs to re-download it in the tests
from what i know, most ci runners dont cache |
Beta Was this translation helpful? Give feedback.
-
We're using github actions to run the ci with the following steps: steps:
- name: Load repository
uses: actions/checkout@master
with:
persist-credentials: false
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 12
cache: 'npm'
env:
REGISTRY_TOKEN: ${{ secrets.REGISTRY_TOKEN }}
- name: Run tests
timeout-minutes: 30
env:
REGISTRY_TOKEN: ${{ secrets.REGISTRY_TOKEN }}
run: |
npm ci
npm run test:cov As for
I wonder if something about this changed, since re-running the job for the CI still tells me that the binary was found in |
Beta Was this translation helpful? Give feedback.
-
Quick update, I found this issue when attempting to update our current CI setup, and I just found out that the issue only happens when using with
with
the cache path is |
Beta Was this translation helpful? Give feedback.
-
I spent some time updating all the packages in our project and was able to update I originally kept both |
Beta Was this translation helpful? Give feedback.
I spent some time updating all the packages in our project and was able to update
@shelf/jest-mongodb
and remove the duplicatedmongodb-memory-server
, and the issue is no longer happening !I originally kept both
mongodb-memory-server
and@shelf/jest-mongodb
in order to move the tests from one to the other one by one over time, but I just ended up moving everything else over now