diff --git a/.github/workflows/pr_donotmerge.yml b/.github/workflows/pr_donotmerge.yml new file mode 100644 index 00000000..1208feaf --- /dev/null +++ b/.github/workflows/pr_donotmerge.yml @@ -0,0 +1,20 @@ +name: Validate pull request (do not merge) + +on: + pull_request: + types: [opened, labeled, unlabeled, synchronize, ready_for_review] + +jobs: + do_not_merge-check: + runs-on: ubuntu-latest + steps: + - name: Has tag + if: github.base_ref == 'main' && contains( github.event.pull_request.labels.*.name, 'pr/do-not-merge') + run: | + echo "PR blocked: [tag: pr/do-not-merge]" + exit 1 + + - name: All good + if: ${{ success() }} + run: | + echo "All good" diff --git a/.github/workflows/pr_validate.yml b/.github/workflows/pr_validate.yml new file mode 100644 index 00000000..f082dc9b --- /dev/null +++ b/.github/workflows/pr_validate.yml @@ -0,0 +1,21 @@ +name: Validate driver + +on: + pull_request: + +jobs: + test: + + runs-on: ubuntu-latest + strategy: + matrix: + dotnet-version: [ '8.0.x' ] + + steps: + - uses: actions/checkout@v4 + - name: Setup dotnet ${{ matrix.dotnet-version }} + uses: actions/setup-dotnet@v3 + with: + dotnet-version: ${{ matrix.dotnet-version }} + - name: Run unit tests on .NET ${{ matrix.dotnet-version }} + run: dotnet test