chore(deps-dev): bump lint-staged from 16.3.3 to 16.4.0 #1098
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: Build and Test | |
| on: | |
| push: | |
| branches: ['main'] | |
| pull_request: | |
| branches: ['main'] | |
| permissions: | |
| contents: read | |
| # Cancel in-progress runs for PRs; never cancel runs on main (merges should not abort each other) | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 15 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| node-version: [20.x, 22.x, 24.x] | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Use Node.js ${{ matrix.node-version }} | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version: ${{ matrix.node-version }} | |
| cache: 'npm' | |
| - name: Configure git for tests | |
| run: | | |
| git config --global user.email "bedrock-agentcore-npm+ci@amazon.com" | |
| git config --global user.name "CI" | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v7 | |
| - run: npm ci | |
| - run: npm run build --if-present | |
| - run: npm run test:unit | |
| - run: npm run test:integ | |
| - name: Upload coverage artifact | |
| if: matrix.node-version == '20.x' | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: coverage-report | |
| path: coverage/ | |
| - name: Pack tarball | |
| if: matrix.node-version == '20.x' | |
| run: npm pack | |
| - name: Install from tarball | |
| if: matrix.node-version == '20.x' | |
| run: npm install -g aws-agentcore-*.tgz | |
| - name: Verify packaged CLI runs | |
| if: matrix.node-version == '20.x' | |
| run: | | |
| agentcore --version | |
| agentcore create --name sanitytest --language Python --framework Strands --model-provider Bedrock --memory none --json | |
| test -f sanitytest/agentcore/agentcore.json | |
| - name: Upload tarball artifact | |
| if: matrix.node-version == '20.x' | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: tarball | |
| path: '*.tgz' | |
| coverage: | |
| needs: build | |
| runs-on: ubuntu-latest | |
| if: github.event_name == 'pull_request' | |
| permissions: | |
| contents: read | |
| pull-requests: write | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Download coverage artifact | |
| uses: actions/download-artifact@v8 | |
| with: | |
| name: coverage-report | |
| path: coverage/ | |
| - name: Coverage Report | |
| uses: davelosert/vitest-coverage-report-action@v2 | |
| with: | |
| json-summary-path: coverage/coverage-summary.json | |
| json-final-path: coverage/coverage-final.json | |
| vite-config-path: vitest.unit.config.ts | |
| file-coverage-mode: none | |
| coverage-thresholds: '{ "lines": 50, "branches": 50, "functions": 50, "statements": 50 }' |