diff --git a/.github/workflows/tests-release.yml b/.github/workflows/tests-release.yml index 2bd4e25..48fc852 100644 --- a/.github/workflows/tests-release.yml +++ b/.github/workflows/tests-release.yml @@ -48,14 +48,7 @@ jobs: uses: actions/setup-node@v3 with: node-version: ${{ matrix.node }} - - - name: Cache dependencies ${{ matrix.node }} - uses: actions/cache@v3 - with: - path: ~/.npm - key: ${{ runner.os }}-node-${{ matrix.node }}-${{ hashFiles('**/package-lock.json') }} - restore-keys: | - ${{ runner.os }}-node-${{ matrix.node }} + cache: npm # for this workflow we also require npm audit to pass - run: npm i - run: npm run test:coverage @@ -96,14 +89,7 @@ jobs: uses: actions/setup-node@v3 with: node-version: ${{ matrix.node }} - - - name: Cache dependencies ${{ matrix.node }} - uses: actions/cache@v3 - with: - path: ~/.npm - key: ${{ runner.os }}-node-${{ matrix.node }}-node-oauth/express-oauth-server-${{ hashFiles('github/testing/express/**/package-lock.json') }} - restore-keys: | - ${{ runner.os }}-node-${{ matrix.node }}-node-oauth/express-oauth-server + cache: npm # in order to test the adapter we need to use the current checkout # and install it as local dependency diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 37b8e22..bea8ee5 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -24,14 +24,7 @@ jobs: uses: actions/setup-node@v3 with: node-version: 20 - - - name: cache dependencies - uses: actions/cache@v3 - with: - path: ~/.npm - key: ${{ runner.os }}-node-16-${{ hashFiles('**/package-lock.json') }} - restore-keys: | - ${{ runner.os }}-node- + cache: npm - run: npm install - run: npm run lint @@ -50,14 +43,7 @@ jobs: uses: actions/setup-node@v3 with: node-version: ${{ matrix.node }} - - - name: Cache dependencies ${{ matrix.node }} - uses: actions/cache@v3 - with: - path: ~/.npm - key: ${{ runner.os }}-node-${{ matrix.node }}-${{ hashFiles('**/package-lock.json') }} - restore-keys: | - ${{ runner.os }}-node-${{ matrix.node }} + cache: npm - run: npm i - run: npm run test:coverage