PR template enhancements (#39402)
diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md
index 1262963..351653e 100644
--- a/.github/PULL_REQUEST_TEMPLATE.md
+++ b/.github/PULL_REQUEST_TEMPLATE.md
@@ -1,19 +1,66 @@
+#### Summary
+
+<!--
+ This section will help the reviewer better understand the context of this change.
+ Please provide a TLDR appropriate to the change's complexity on what was changed and why.
+ If fixing an error, explain the root cause and the chosen solution's rationale, especially if not obvious.
+ Include context like links to related documents/issues/test plans and highlight notable information or specific concerns.
+
+ See guidelines: https://project-chip.github.io/connectedhomeip-doc/pull_request_guidelines.html#pr-summary-description
+ See title formatting: https://project-chip.github.io/connectedhomeip-doc/pull_request_guidelines.html#title-formatting
+
+ Examples:
+ [TODO] – find an example of a good PR description
+
+ Please replace this HTML comment with the actual PR summary.
+-->
+
+#### Related issues
+
+<!--
+ This section will help the reviewer easily navigate to the GitHub issues related to this PR change.
+ Please mention all the related issues in this section.
+
+ Tip: use the syntax of Fixes #.... to mark issues completed on PR merge or use #... to reference issues that are addressed.
+
+ Examples:
+ Fixes: #12345
+ #12345
+ N/A (not preferable)
+
+ Please replace this HTML comment with the actual information about related issues.
+-->
#### Testing
-> !!!!!!!!!! Please delete the instructions below and replace with PR
-> description above.
->
-> If you have an issue number, please use a syntax of `Fixes #12345` and a brief
-> change description
->
-> If you do not have an issue number, please have a good description of the
-> problem and the fix. Help the reviewer understand what to expect.
->
-> Complete/append to the `### Testing` section above, to describe how testing
-> was done. See
-> <https://github.com/project-chip/connectedhomeip/blob/master/CONTRIBUTING.md#pull-requests>
->
-> Make sure you delete these instructions (to prove you have read them).
->
-> !!!!!!!!!! Instructions end
+<!--
+ This section will help the reviewer understand how this PR change was tested.
+ As a general rule, a proposed PR change must not break the existing code and must be well-tested.
+ Please include information about testing.
+
+ See testing guidelines: https://project-chip.github.io/connectedhomeip-doc/pull_request_guidelines.html#testing
+
+ Examples:
+ added unit tests
+ verified by YAML test: TC_ABC.yaml
+ added Python test: TC_DEF.py
+ manually tested (mention steps to reproduce)
+
+ Please replace this HTML comment with the actual information about how the testing was done.
+ -->
+
+#### Readability checklist
+
+The checklist below will help the reviewer finish PR review in time and keep the
+code readable:
+
+- [ ] PR title is
+ [descriptive](https://project-chip.github.io/connectedhomeip-doc/pull_request_guidelines.html#title-formatting)
+- [ ] Apply the
+ [_“When in Rome…”_](https://project-chip.github.io/connectedhomeip-doc/style/CODING_STYLE_GUIDE.html)
+ rule (coding style)
+- [ ] PR size is short
+- [ ] Try to avoid "squashing" and "force-update" in commit history
+- [ ] CI time didn't increase
+
+See: [PULL_REQUEST_GUIDELINES.md](../docs/pull_request_guidelines.md)
diff --git a/.github/workflows/pr-validation.yaml b/.github/workflows/pr-validation.yaml
index 8d94eb8..3ba6532 100644
--- a/.github/workflows/pr-validation.yaml
+++ b/.github/workflows/pr-validation.yaml
@@ -26,7 +26,7 @@
${{ github.event.pull_request.body }}
EndMarkerForPrSummary
- python -c 'import sys; pr_summary = open("/tmp/pr-summary.txt", "rt").read(); sys.exit(1 if "Make sure you delete these instructions" in pr_summary else 0)'
+ python -c 'import sys; pr_summary = open("/tmp/pr-summary.txt", "rt").read(); sys.exit(1 if "<!--" in pr_summary or "-->" in pr_summary else 0)'
# NOTE: comments disabled for now as separate permissions are required
# failing CI step may be sufficient to start (although it contains less information about why it failed)
@@ -67,4 +67,3 @@
run: |
python -c 'import sys; print("Testing section missing (test failed)"); sys.exit(1)'
-