Edit doc comments (#1228) #982
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
name: Continuous Integration | |
on: | |
pull_request: | |
push: | |
branches: | |
- master | |
jobs: | |
build-and-test: | |
strategy: | |
matrix: | |
go-version: ["1.20", "1.21"] | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
- uses: actions/setup-go@v4 | |
with: | |
go-version: ${{ matrix.go-version }} | |
- name: Check and unit test | |
run: make check unit-test | |
- name: Clone Temporal Docker compose | |
uses: actions/checkout@v3 | |
with: | |
repository: temporalio/docker-compose | |
path: ./docker-compose | |
- name: Start Temporal server | |
run: | | |
cp ./.github/workflows/docker/docker-compose.override.yaml ./docker-compose/docker-compose.override.yaml | |
cp ./.github/workflows/docker/dynamic-config-custom.yaml ./docker-compose/dynamicconfig/dynamic-config-custom.yaml | |
docker-compose --project-directory ./docker-compose up & | |
go run ./.github/workflows/wait_for_server.go | |
- name: Integration tests (without cache) | |
run: make integration-test-zero-cache | |
- name: Integration tests (with cache) | |
run: make integration-test-normal-cache | |
- name: Merge coverage files | |
id: merge-coverage-files | |
run: | | |
COVERAGE_FILE="$(mktemp)" | |
echo "COVERAGE_FILE=$COVERAGE_FILE" >> "$GITHUB_OUTPUT" | |
make merge-coverage > "$COVERAGE_FILE" | |
- name: Upload coverage | |
continue-on-error: true | |
uses: coverallsapp/github-action@v2 | |
with: | |
file: ${{ steps.merge-coverage-files.outputs.COVERAGE_FILE }} | |
format: golang | |
cloud-test: | |
strategy: | |
matrix: | |
go-version: ["1.20", "1.21"] | |
# Only supported in non-fork runs, since secrets are not available in forks. | |
if: ${{ github.event.pull_request.head.repo.full_name == '' || github.event.pull_request.head.repo.full_name == 'temporalio/sdk-go' }} | |
runs-on: ubuntu-latest | |
env: | |
SERVICE_ADDR: tinycicd.sdk.tmprl.cloud:7233 | |
TEMPORAL_NAMESPACE: tinycicd.sdk | |
TEMPORAL_CLIENT_CERT: ${{ secrets.TEMPORAL_CLIENT_CERT }} | |
TEMPORAL_CLIENT_KEY: ${{ secrets.TEMPORAL_CLIENT_KEY }} | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
- uses: actions/setup-go@v4 | |
with: | |
go-version: ${{ matrix.go-version }} | |
- name: Single integration test against cloud | |
run: 'go test -v --count 1 -p 1 . -run "TestIntegrationSuite/TestBasic$"' | |
working-directory: test | |
features-test: | |
uses: temporalio/features/.github/workflows/go.yaml@main | |
with: | |
go-repo-path: ${{github.event.pull_request.head.repo.full_name}} | |
version: ${{github.event.pull_request.head.ref}} | |
version-is-repo-ref: true | |