diff --git a/.github/workflows/test-astra.yaml b/.github/workflows/test-astra.yaml index 885bc04..7f4ae99 100644 --- a/.github/workflows/test-astra.yaml +++ b/.github/workflows/test-astra.yaml @@ -16,6 +16,10 @@ env: ASTRA_DB_TOKEN: ${{ secrets.ASTRA_DB_TOKEN }} ASTRA_DB_DATABASE_NAME: ${{ secrets.ASTRA_DB_DATABASE_NAME }} +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} # should probably be globally unique + cancel-in-progress: true + jobs: test: runs-on: ubuntu-latest diff --git a/.github/workflows/test-docs-compilation.yml b/.github/workflows/test-docs-compilation.yml new file mode 100644 index 0000000..c559fdc --- /dev/null +++ b/.github/workflows/test-docs-compilation.yml @@ -0,0 +1,43 @@ +name: Compile against documentation examples + +on: + pull_request: + branches: + - main + +permissions: + pull-requests: write + contents: read + +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + +jobs: + test-compilation: + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v6 + + - name: Run compilation tests + id: compile-step + uses: datastax/astra-client-docs-tests/.github/actions/test-compilation@master + with: + clients: 'csharp' + args: -A csharp='' + allow-failures: 'true' + docs-repo-token: ${{ secrets.DOC_GITHUB_PAT_CROSS_ORG }} + docs-repo: '@ske-csharp-client' + + - name: Label PR on failure + uses: actions-ecosystem/action-add-labels@v1 + if: steps.compile-step.outputs.failed_tests == 'true' && github.event.pull_request + with: + labels: 'Breaks Docs Compilation Tests' + + - name: Remove label on success + uses: actions-ecosystem/action-remove-labels@v1 + if: steps.compile-step.outputs.failed_tests == 'false' && github.event.pull_request + with: + labels: 'Breaks Docs Compilation Tests' diff --git a/.github/workflows/test-hcd.yaml b/.github/workflows/test-hcd.yaml index 279fded..20c5d35 100644 --- a/.github/workflows/test-hcd.yaml +++ b/.github/workflows/test-hcd.yaml @@ -1,12 +1,12 @@ name: Run integration tests on HCD + Data API on: - push: - branches: - - main - pull_request: - branches: - - main +# push: +# branches: +# - main +# pull_request: +# branches: +# - main permissions: id-token: write # required for OIDC @@ -20,6 +20,10 @@ env: AWS_ECR_REGISTRY: ${{ secrets.AWS_ECR_REGISTRY }} AWS_ECR_HCD_IMAGE_TAG: "1.2.3" +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + jobs: test: env: