From c0fc8348e6ba9f7ccf6b79ec774c36df5d775267 Mon Sep 17 00:00:00 2001 From: Dawa Ometto Date: Thu, 12 Sep 2024 15:11:44 +0200 Subject: [PATCH] chore: only run tests for non-draft PRs --- .github/workflows/molecule_playbooks.yml | 6 ++++++ .github/workflows/molecule_roles.yml | 6 ++++++ CONTRIBUTING.md | 2 ++ 3 files changed, 14 insertions(+) diff --git a/.github/workflows/molecule_playbooks.yml b/.github/workflows/molecule_playbooks.yml index 30e76e4d..a6c1a5b4 100644 --- a/.github/workflows/molecule_playbooks.yml +++ b/.github/workflows/molecule_playbooks.yml @@ -7,10 +7,16 @@ on: pull_request: branches: - main + types: + - opened + - reopened + - synchronize + - ready_for_review jobs: define_scenarios: + if: github.event.pull_request.draft == false runs-on: ubuntu-latest steps: - name: Checkout diff --git a/.github/workflows/molecule_roles.yml b/.github/workflows/molecule_roles.yml index 8b306eea..7c0662c6 100644 --- a/.github/workflows/molecule_roles.yml +++ b/.github/workflows/molecule_roles.yml @@ -7,10 +7,16 @@ on: pull_request: branches: - main + types: + - opened + - reopened + - synchronize + - ready_for_review jobs: get_changed_roles: + if: github.event.pull_request.draft == false runs-on: ubuntu-latest outputs: matrix: ${{ steps.changed-roles.outputs.all_changed_files }} diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 0da4bddd..aa611f24 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -17,6 +17,8 @@ In short: 5. Submit a pull request from that branch to the main branch of the master repository. 6. If you receive feedback, make changes on your desktop and push to your branch on GitHub: the pull request will update automatically. +**Note**: in order not to needlessly trigger test workflows, please convert your PR to a draft while you are still working on it. When ready, mark your PR as "ready for review". This will ensure tests are run. + ## Style guides ### Branch naming conventions