|
30 | 30 | name: test-results
|
31 | 31 | path: coverage/lcov.info
|
32 | 32 |
|
33 |
| - run-atlas-tests: |
34 |
| - name: Run Atlas tests |
35 |
| - if: github.event.pull_request.user.login == 'dependabot[bot]' |
36 |
| - runs-on: ubuntu-latest |
37 |
| - steps: |
38 |
| - - uses: GitHubSecurityLab/actions-permissions/monitor@v1 |
39 |
| - - uses: actions/checkout@v4 |
40 |
| - - uses: actions/setup-node@v4 |
41 |
| - with: |
42 |
| - node-version-file: package.json |
43 |
| - cache: "npm" |
44 |
| - - name: Install dependencies |
45 |
| - run: npm ci |
46 |
| - - name: Run tests |
47 |
| - env: |
48 |
| - MDB_MCP_API_CLIENT_ID: ${{ secrets.TEST_ATLAS_CLIENT_ID }} |
49 |
| - MDB_MCP_API_CLIENT_SECRET: ${{ secrets.TEST_ATLAS_CLIENT_SECRET }} |
50 |
| - MDB_MCP_API_BASE_URL: ${{ vars.TEST_ATLAS_BASE_URL }} |
51 |
| - run: npm test -- --testPathIgnorePatterns "tests/integration/tools/mongodb" --testPathIgnorePatterns "tests/integration/[^/]+\.ts" |
52 |
| - - name: Upload test results |
53 |
| - uses: actions/upload-artifact@v4 |
54 |
| - if: always() |
55 |
| - with: |
56 |
| - name: atlas-test-results |
57 |
| - path: coverage/lcov.info |
58 |
| - |
59 |
| - coverage: |
60 |
| - name: Report Coverage |
61 |
| - if: github.event.pull_request.user.login == 'dependabot[bot]' |
62 |
| - runs-on: ubuntu-latest |
63 |
| - needs: [run-tests, run-atlas-tests] |
64 |
| - steps: |
65 |
| - - uses: actions/checkout@v4 |
66 |
| - - uses: actions/setup-node@v4 |
67 |
| - with: |
68 |
| - node-version-file: package.json |
69 |
| - cache: "npm" |
70 |
| - - name: Install dependencies |
71 |
| - run: npm ci |
72 |
| - - name: Download test results |
73 |
| - uses: actions/download-artifact@v4 |
74 |
| - with: |
75 |
| - name: test-results |
76 |
| - path: coverage/mongodb |
77 |
| - - name: Download atlas test results |
78 |
| - uses: actions/download-artifact@v4 |
79 |
| - with: |
80 |
| - name: atlas-test-results |
81 |
| - path: coverage/atlas |
82 |
| - - name: Merge coverage reports |
83 |
| - run: | |
84 |
| - npx -y lcov-result-merger@5.0.1 "coverage/*/lcov.info" "coverage/lcov.info" |
85 |
| - - name: Coveralls GitHub Action |
86 |
| - uses: coverallsapp/github-action@v2.3.6 |
87 |
| - with: |
88 |
| - file: coverage/lcov.info |
89 |
| - git-branch: ${{ github.head_ref || github.ref_name }} |
90 |
| - git-commit: ${{ github.event.pull_request.head.sha || github.sha }} |
91 |
| - |
92 | 33 | merge-dependabot-pr:
|
93 | 34 | name: Merge Dependabot PR
|
94 | 35 | if: github.event.pull_request.user.login == 'dependabot[bot]'
|
|
0 commit comments