Skip to content

CodeRabbit Generated Unit Tests: Add tests for docs, PR templates, and CHANGELOG; remove examples/ dir - #9

Merged
ashleyshaw merged 4 commits into
chore/add-pr-templates-add-docsfrom
coderabbitai/utg/c10a7db
Oct 12, 2025
Merged

CodeRabbit Generated Unit Tests: Add tests for docs, PR templates, and CHANGELOG; remove examples/ dir#9
ashleyshaw merged 4 commits into
chore/add-pr-templates-add-docsfrom
coderabbitai/utg/c10a7db

Conversation

@coderabbitai

Copy link
Copy Markdown
Contributor

Unit test generation was requested by @ashleyshaw.

The following files were modified:

  • tests/test_branch_prefix_docs.py
  • tests/test_changelog.py
  • tests/test_docs_links.py
  • tests/test_markdown_structure.py
  • tests/test_pr_templates.py
  • tests/test_removed_examples_references.py
  • tests/util_changed_files.py

@coderabbitai

Copy link
Copy Markdown
ContributorAuthor

Important

Review skipped

CodeRabbit bot authored PR detected.

To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.


Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitaicoderabbitaiBot mentioned this pull request Oct 12, 2025
9 tasks

CopilotAI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds comprehensive unit tests for documentation quality, PR templates, and repository structure validation. The tests ensure consistent formatting, working links, proper CHANGELOG structure, and verify that references to the removed examples/ directory have been cleaned up.

Key changes:

  • Adds 6 test modules covering different aspects of documentation validation
  • Creates a utility module for identifying changed files and filtering by type
  • Implements tests for markdown structure, link validation, PR template requirements, and CHANGELOG format

Reviewed Changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.

Show a summary per file
FileDescription
tests/util_changed_files.pyUtility functions for detecting changed files via git and filtering by type
tests/test_removed_examples_references.pyValidates that stale references to the removed examples/ directory are eliminated
tests/test_pr_templates.pyEnsures PR templates contain required sections like "Linked issues" and "Changelog"
tests/test_markdown_structure.pyValidates markdown formatting rules (no tabs, line length, H1 headers, etc.)
tests/test_docs_links.pyChecks that relative links in documentation point to existing files
tests/test_changelog.pyVerifies CHANGELOG.md follows proper structure with Unreleased sections
tests/test_branch_prefix_docs.pyValidates branch prefix documentation contains valid regex patterns

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Comment threadtests/util_changed_files.py Outdated
Comment threadtests/test_branch_prefix_docs.py Outdated
Comment threadtests/test_markdown_structure.py Outdated
ashleyshawand others added 3 commits October 12, 2025 11:02
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Ash Shaw <ashley@lightspeedwp.agency>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Ash Shaw <ashley@lightspeedwp.agency>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Ash Shaw <ashley@lightspeedwp.agency>
@ashleyshaw

Copy link
Copy Markdown
Member

@coderabitai how do I run the tests?

@ashleyshaw
ashleyshaw merged commit 38a0401 into chore/add-pr-templates-add-docsOct 12, 2025
4 of 6 checks passed
@ashleyshaw
ashleyshaw deleted the coderabbitai/utg/c10a7db branch October 12, 2025 04:04
ashleyshaw added a commit that referenced this pull request Jul 22, 2026
* fix(validation): address footer truncation and mermaid workflow issues
- Fix validate-footers.js to preserve file bodies when appending footers
(issue #1118: replaceFooterTail was using last --- separator instead of
frontmatter closing separator, truncating content after closing ---)
- Improve validate-mermaid-pr.yml error handling and robustness
(issue #1119: add graceful fallback when git diff fails, better handle
edge cases where no changes detected)
Test coverage gaps noted (to address on feat/agent-standards-playwright-testing):
- agent-spec-validator needs tests for empty/non-array capabilities
- multi-provider-consistency-checker needs tests for unsupported providers
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
* fix(docs): use UK spelling 'standardised' in initiative memory
Addresses CodeRabbit feedback: replace 'standardized' with 'standardised' to
match repository's UK English documentation standard.
Refs: CodeRabbit feedback on PR #1108
* docs(changelog): add entry for validation tool fixes (PR #1123)
Add CHANGELOG entry documenting the footer truncation bug fix and mermaid
workflow robustness improvements from PR #1123.
Closes: #1118, #1119
Refs: PR #1123
* fix: resolve pre-existing linting errors (MD012 blank lines)
Fixed 5 instruction files with multiple consecutive blank lines before footer separator — these pre-existing issues were blocking PR #1123 CI checks.
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
* chore: apply CodeRabbit improvements from #1126 (Phase 1)
Applied improvements for existing files:
- UK spelling: standardization → standardisation (4 audit reports, 1 framework)
- UK spelling: organization → organisation (1 framework)
- UK spelling: customization → customisation (1 framework)
- Phase 1C-J implementation status: PENDING → COMPLETED (framework)
- Deleted unfinished Gemini plugin at plugins/lightspeed-playwright-testing/.gemini-plugin/plugin.json
Pending improvements (awaiting hook implementation):
- Improvements #5-9: Plugin integrity hook fixes and enhancements
- Improvements #6-7: Test fixture cleanup and JSDoc for missing hooks
- Improvement #8: hooks/package.json scripts (file doesn't exist yet)
- Improvement #9: Expanded test coverage for hooks
- Improvement #10: Cookbook playwright guide (file doesn't exist yet)
- Improvement #11: Plugin integrity hook documentation
- Improvement #12: Isolate plugin integrity unit tests
See issue #1126 for full details.
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Haiku 4.5 <noreply@anthropic.com>
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@ashleyshaw