This is an automated email from the ASF dual-hosted git repository.
adoroszlai pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ozone.git
The following commit(s) were added to refs/heads/master by this push:
new 6035201cc3 HDDS-9406. Do not run all checks for draft PR touching CI
files (#5406)
6035201cc3 is described below
commit 6035201cc30d18ea311b9b248b71b1fa0251d019
Author: Doroszlai, Attila <[email protected]>
AuthorDate: Tue Oct 31 13:31:30 2023 +0100
HDDS-9406. Do not run all checks for draft PR touching CI files (#5406)
---
.github/workflows/ci.yml | 1 +
dev-support/ci/selective_ci_checks.bats | 13 +++++++++++++
dev-support/ci/selective_ci_checks.sh | 2 +-
3 files changed, 15 insertions(+), 1 deletion(-)
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 9c6fe4d691..e3b38fe42e 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -139,6 +139,7 @@ jobs:
needs:
- build-info
- build
+ - basic
runs-on: ubuntu-20.04
timeout-minutes: 30
if: needs.build-info.outputs.needs-compile == 'true'
diff --git a/dev-support/ci/selective_ci_checks.bats
b/dev-support/ci/selective_ci_checks.bats
index b5b3d2aeaf..243ae283c1 100644
--- a/dev-support/ci/selective_ci_checks.bats
+++ b/dev-support/ci/selective_ci_checks.bats
@@ -297,6 +297,19 @@ load bats-assert/load.bash
assert_output -p needs-kubernetes-tests=true
}
+@test "draft CI workflow change" {
+ export PR_DRAFT=true
+ run dev-support/ci/selective_ci_checks.sh 90fd5f2adc
+
+ assert_output -p 'basic-checks=[]'
+ assert_output -p needs-build=false
+ assert_output -p needs-compile=false
+ assert_output -p needs-compose-tests=false
+ assert_output -p needs-dependency-check=false
+ assert_output -p needs-integration-tests=false
+ assert_output -p needs-kubernetes-tests=false
+}
+
@test "CI workflow change (ci.yaml)" {
run dev-support/ci/selective_ci_checks.sh 90fd5f2adc
diff --git a/dev-support/ci/selective_ci_checks.sh
b/dev-support/ci/selective_ci_checks.sh
index 7527c7a624..0bd6321734 100755
--- a/dev-support/ci/selective_ci_checks.sh
+++ b/dev-support/ci/selective_ci_checks.sh
@@ -588,8 +588,8 @@ fi
get_changed_files
-run_all_tests_if_environment_files_changed
check_if_tests_are_needed_at_all
+run_all_tests_if_environment_files_changed
get_count_all_files
get_count_compose_files
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]