Skip to content

Commit 95197d5

Browse files
committed
feat(pingcap/tidb): block mergeing for pull requests which have none finished test tasks
Signed-off-by: wuhuizuo <[email protected]>
1 parent c7fb2a0 commit 95197d5

File tree

3 files changed

+22
-0
lines changed

3 files changed

+22
-0
lines changed

prow/config/config.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2398,6 +2398,7 @@ tide:
23982398
- do-not-merge/invalid-owners-file
23992399
- do-not-merge/invalid-title
24002400
- do-not-merge/needs-linked-issue
2401+
- do-not-merge/needs-finished-tests
24012402
- do-not-merge/needs-triage-completed
24022403
- do-not-merge/release-note-label-needed
24032404
- do-not-merge/work-in-progress

prow/config/external_plugins_config.yaml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -931,6 +931,24 @@ ti-community-format-checker:
931931
<sub>:open_book: For more info, you can check the ["Contribute Code"](https://pingcap.github.io/tidb-dev-guide/contribute-to-tidb/contribute-code.html#referring-to-an-issue) section in the development guide.</sub>
932932
missing_label: do-not-merge/needs-linked-issue
933933
skip_label: skip-issue-check
934+
- pull_request: true
935+
body: true
936+
branches: [master]
937+
regexp: "\\\\n\\\\bTests <!-- At least one of them must be included\\\\. -->\\\\s*[\\\\n]{1,}(- \\\\[[xX ]\\\\] .*\\\\n)*(- \\\\[[xX]\\\\] .*\\\\n)(- \\\\[[xX ]\\\\] .*\\\\n)*\\\\n"
938+
missing_label: do-not-merge/needs-finished-tests
939+
missing_message: |
940+
**Notice**: To remove the `do-not-merge/needs-finished-tests` label, please finished the test for the pull request and check the finished items in description.
941+
942+
For example:
943+
944+
> Tests <!-- At least one of them must be included. -->
945+
>
946+
> - [x] Unit test
947+
> - [ ] Integration test
948+
> - [ ] Manual test (add detailed scripts or steps below)
949+
> - [ ] No code
950+
951+
<sub>:open_book: For more info, you can check the ["Contribute Code"](https://pingcap.github.io/tidb-dev-guide/contribute-to-tidb/contribute-code.html#writing-tests) section in the development guide.</sub>
934952
- repos:
935953
- pingcap/tidb-tools
936954
- pingcap/tidb-binlog

prow/config/labels.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2794,6 +2794,9 @@ repos:
27942794
- name: do-not-merge/needs-linked-issue
27952795
color: "e11d21"
27962796
target: both
2797+
- name: do-not-merge/needs-finished-tests
2798+
color: "e11d21"
2799+
target: prs
27972800
- name: do-not-merge/invalid-title
27982801
color: "e11d21"
27992802
target: prs

0 commit comments

Comments
 (0)