Upgrade mongodb7 #18
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Run Tests | |
| on: | |
| push: | |
| branches: | |
| - master | |
| pull_request: | |
| types: ['opened', 'reopened', 'synchronize'] | |
| jobs: | |
| test: | |
| strategy: | |
| matrix: | |
| nodejs: [ '20', '22', '24', '25' ] | |
| mongodb-version: [ '6.0', '7.0', '8.0' ] | |
| runs-on: ubuntu-latest | |
| permissions: | |
| actions: write | |
| contents: read | |
| pull-requests: write | |
| steps: | |
| - name: Cancel Previous Runs | |
| uses: styfle/cancel-workflow-action@0.11.0 | |
| with: | |
| access_token: ${{ github.token }} | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v4 | |
| with: | |
| run_install: false | |
| - name: Use Node.js ${{ matrix.nodejs }} | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: ${{ matrix.nodejs }} | |
| - name: Start MongoDB | |
| uses: supercharge/mongodb-github-action@1.12.1 | |
| with: | |
| mongodb-version: ${{ matrix.mongodb-version }} | |
| mongodb-replica-set: rs0 | |
| - run: pnpm install --frozen-lockfile | |
| - run: pnpm test |