summaryrefslogtreecommitdiff
path: root/tooling/danger/stable_branch.rb
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2023-03-03 12:10:00 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2023-03-03 12:10:00 +0000
commit14a32c2d551a646525b1fabd93cb70a0e6924478 (patch)
tree782ba91ba786aee2cda379704e7f2ebcb5b46748 /tooling/danger/stable_branch.rb
parent11c2f3b08c3bab4718a97360d1502f90793d028b (diff)
downloadgitlab-ce-14a32c2d551a646525b1fabd93cb70a0e6924478.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'tooling/danger/stable_branch.rb')
-rw-r--r--tooling/danger/stable_branch.rb12
1 files changed, 9 insertions, 3 deletions
diff --git a/tooling/danger/stable_branch.rb b/tooling/danger/stable_branch.rb
index aaaf3cbea8c..2d1a4ef0845 100644
--- a/tooling/danger/stable_branch.rb
+++ b/tooling/danger/stable_branch.rb
@@ -58,7 +58,7 @@ module Tooling
# rubocop:disable Style/SignalException
def check!
- return unless non_security_stable_branch?
+ return unless valid_stable_branch?
fail FEATURE_ERROR_MESSAGE if has_feature_label?
fail BUG_ERROR_MESSAGE unless bug_fixes_only?
@@ -79,12 +79,18 @@ module Tooling
end
# rubocop:enable Style/SignalException
- def non_security_stable_branch?
- !!stable_target_branch && !helper.security_mr?
+ def encourage_package_and_qa_execution?
+ valid_stable_branch? &&
+ !has_only_documentation_changes? &&
+ !has_flaky_failure_label?
end
private
+ def valid_stable_branch?
+ !!stable_target_branch && !helper.security_mr?
+ end
+
def package_and_test_status
mr_head_pipeline_id = gitlab.mr_json.dig('head_pipeline', 'id')
return unless mr_head_pipeline_id