Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 31 additions & 3 deletions .github/workflows/build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,12 @@ jobs:
cache: 'npm'
- name: Configure git for tests
run: |
git config --global user.email "bedrock-agentcore-npm+ci@amazon.com"
git config --global user.email "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:integ
- name: Pack tarball
if: matrix.node-version == '20.x'
run: npm pack
Expand All @@ -63,6 +62,35 @@ jobs:
name: tarball
path: '*.tgz'

integ-test:
runs-on: ubuntu-latest
timeout-minutes: 15

strategy:
fail-fast: false
matrix:
node-version:
${{ github.event_name == 'pull_request' && fromJSON('["20.x"]') || fromJSON('["20.x", "22.x", "24.x"]') }}
shard: [1/4, 2/4, 3/4, 4/4]

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 "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
- name: Run integration tests (shard ${{ matrix.shard }})
run: npx vitest run --project integ --shard=${{ matrix.shard }}

unit-test:
runs-on: ubuntu-latest
timeout-minutes: 15
Expand All @@ -83,7 +111,7 @@ jobs:
cache: 'npm'
- name: Configure git for tests
run: |
git config --global user.email "bedrock-agentcore-npm+ci@amazon.com"
git config --global user.email "ci@amazon.com"
git config --global user.name "CI"
- name: Install uv
uses: astral-sh/setup-uv@v7
Expand Down
Loading