Skip to content

ci: allow docs-only pull requests to skip tests#12174

Merged
Adam-Aghili merged 2 commits intomainfrom
docs-decouple-from-ci
Mar 13, 2026
Merged

ci: allow docs-only pull requests to skip tests#12174
Adam-Aghili merged 2 commits intomainfrom
docs-decouple-from-ci

Conversation

@mendonk
Copy link
Collaborator

@mendonk mendonk commented Mar 12, 2026

If a pull request only changes files at docs/**, the workflow will skip running Python, Jest, and TypeScript tests, saving CI resources and time. The docs PR can also still merge if the nightly build is failing.

The docs-only path filter is defined in ci.yml.

Summary by CodeRabbit

  • Chores
    • Optimized CI pipeline to skip test runs when only documentation updates are made, improving workflow efficiency and reducing unnecessary processing time.

@mendonk mendonk requested a review from Adam-Aghili March 12, 2026 19:45
@mendonk mendonk self-assigned this Mar 12, 2026
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Mar 12, 2026

Important

Review skipped

Auto incremental reviews are disabled on this repository.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: b7c249ec-1138-46c0-8ba9-0f1e7f9751a9

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

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Walkthrough

Updates the CI workflow configuration to add guard conditions preventing test execution when only documentation changes are detected. Three test jobs (test-backend, test-frontend-unit, test-frontend) now require the docs-only check to be false before running, using the needs.path-filter.outputs.docs-only != 'true' condition.

Changes

Cohort / File(s) Summary
CI Workflow Updates
.github/workflows/ci.yml
Adds docs-only guard conditions to test-backend, test-frontend-unit, and test-frontend jobs to prevent test execution when only documentation changes are detected.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

🚥 Pre-merge checks | ✅ 7
✅ Passed checks (7 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely summarizes the main change: allowing docs-only pull requests to skip tests by adding path-based CI conditionals.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Test Coverage For New Implementations ✅ Passed CI workflow configuration changes fall outside the scope of product code features requiring test coverage.
Test Quality And Coverage ✅ Passed PR contains only CI workflow configuration changes without new functionality implementations, making test coverage evaluation not applicable.
Test File Naming And Structure ✅ Passed This custom check is not applicable to the provided pull request. The PR exclusively modifies the CI workflow configuration in .github/workflows/ci.yml to implement docs-only path filtering logic and does not create, modify, or change any test files. Since the check is designed to evaluate test file naming patterns, structure, and organization (backend test_*.py files, frontend *.test.ts/tsx files, etc.), and no test files were modified in this PR, the check cannot be meaningfully applied.
Excessive Mock Usage Warning ✅ Passed This pull request does not modify any test files, making the Excessive Mock Usage Warning check not applicable.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch docs-decouple-from-ci
📝 Coding Plan
  • Generate coding plan for human review comments

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@github-actions
Copy link
Contributor

github-actions bot commented Mar 12, 2026

Frontend Unit Test Coverage Report

Coverage Summary

Lines Statements Branches Functions
Coverage: 24%
24.14% (8609/35660) 16.89% (4743/28067) 16.87% (1261/7473)

Unit Test Results

Tests Skipped Failures Errors Time
2776 0 💤 0 ❌ 0 🔥 45.695s ⏱️

@codecov
Copy link

codecov bot commented Mar 12, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 38.26%. Comparing base (bc2da11) to head (b1ddc5a).
⚠️ Report is 8 commits behind head on main.

❌ Your project status has failed because the head coverage (44.32%) is below the target coverage (60.00%). You can increase the head coverage or adjust the target coverage.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main   #12174      +/-   ##
==========================================
- Coverage   38.27%   38.26%   -0.01%     
==========================================
  Files        1630     1630              
  Lines       80233    80238       +5     
  Branches    12114    12114              
==========================================
- Hits        30708    30702       -6     
- Misses      47788    47800      +12     
+ Partials     1737     1736       -1     
Flag Coverage Δ
backend 56.76% <ø> (-0.05%) ⬇️
frontend 21.56% <ø> (ø)
lfx 44.32% <ø> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.
see 8 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In @.github/workflows/ci.yml:
- Around line 239-240: The condition allows tests to run when the path-filter
job was skipped because needs.path-filter.outputs.docs-only is null; update the
test job conditions (for test-frontend-unit, test-frontend and the occurrence
using needs.set-ci-condition and needs.path-filter) to first verify path-filter
actually ran by checking needs.path-filter.result != 'skipped' (or == 'success')
before evaluating needs.path-filter.outputs.docs-only != 'true' so that a
skipped path-filter does not cause null != 'true' to pass; in short, add a guard
like needs.path-filter.result != 'skipped' &&
needs.path-filter.outputs.docs-only != 'true' alongside the existing
should-run-tests check.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 7421b1c5-2860-43b2-86bc-532f25c2e56a

📥 Commits

Reviewing files that changed from the base of the PR and between bc2da11 and a3d94ef.

📒 Files selected for processing (1)
  • .github/workflows/ci.yml

Copy link
Collaborator

@Adam-Aghili Adam-Aghili left a comment

Choose a reason for hiding this comment

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

LGTM

@github-actions github-actions bot added the lgtm This PR has been approved by a maintainer label Mar 12, 2026
@Adam-Aghili Adam-Aghili added this pull request to the merge queue Mar 13, 2026
Merged via the queue into main with commit ba8dab1 Mar 13, 2026
94 of 95 checks passed
@Adam-Aghili Adam-Aghili deleted the docs-decouple-from-ci branch March 13, 2026 16:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lgtm This PR has been approved by a maintainer

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants