-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
60 additions
and
26 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
name: List API | ||
on: | ||
pull_request: | ||
paths: | ||
- 'infrastructure/list-api/**' | ||
- 'packages/**' | ||
- 'servers/list-api/**' | ||
- 'pnpm-lock.yaml' | ||
- '.github/actions/**' | ||
- '.github/workflows/list_api.yml' | ||
|
||
jobs: | ||
test-integrations: | ||
uses: ./.github/workflows/test_integrations.yml | ||
with: | ||
scope: 'list-api' | ||
# Ensure the re-usable workflow is allowed to access the secrets | ||
secrets: inherit |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
name: 'Re-usable Test Integrations' | ||
on: | ||
workflow_call: | ||
inputs: | ||
scope: | ||
description: 'Turbo Repo scope to run tests for' | ||
required: true | ||
type: string | ||
|
||
jobs: | ||
test-integrations: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Login to Docker Hub | ||
uses: docker/login-action@v3 | ||
with: | ||
username: ${{ secrets.DOCKERHUB_USERNAME }} | ||
password: ${{ secrets.DOCKERHUB_TOKEN }} | ||
|
||
# Kick off starting docker compose first, since it can take a bit | ||
- name: Start Docker Compose services | ||
run: docker compose up -d | ||
|
||
# While we wait for docker compose to be healthy we install node and needed packages. | ||
- name: Install pnpm & node | ||
uses: ./.github/actions/install-pnpm-and-node | ||
with: | ||
scope: ${{ inputs['scope'] }} | ||
|
||
# Step 4: Wait for the services to be healthy | ||
- name: Wait for services to be healthy | ||
run: docker compose up --wait | ||
- name: Run service integration tests | ||
run: pnpm run test-integrations --filter=${{ inputs['scope'] }} |
This file contains 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