Skip to content

ci: skip the heavy unit-tests suite for docs-only merge groups - #16413

Merged
Maffooch merged 1 commit into
devfrom
ci/merge-queue-docs-only-skip
Oct 19, 2026
Merged

Maffooch merged 1 commit into
devfrom
ci/merge-queue-docs-only-skip

Conversation

@Maffooch

@Maffooch Maffooch commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

Shortcut: sc-16697

Summary

The docs-only skip in unit-tests.yml (#15699, #15712) only looked at pull_request events. On merge_group the detection step never ran, so every queued docs PR rebuilt both platforms and ran the full suite before landing.

This extends the changes job to the merge queue:

  • On merge_group, it diffs merge_group.base_sha against merge_group.head_sha. The head commit includes every entry queued ahead, so the heavy jobs skip only when that whole union touches nothing outside docs/. The code under test is then identical to the base, which already passed through the queue.
  • The diff uses two depth-1 git fetches instead of the compare API, which truncates at 300 files.
  • Parser doc pages (docs/content/supported_tools/parsers/) no longer count as docs-only on either event. unittests/test_parsers.py checks that every parser has a doc page and every doc page has a parser, so renaming or deleting one can break the suite.
  • It still fails open: if the listing fails, docs_only stays false and the full suite runs. Unit Tests Complete accepts a skipped dependency only when docs_only is true.

I ran the step's script locally against real dev commits: a docs-only commit (#16406) gives true, a code fix (#16409) gives false, and bogus SHAs give false with exit 0. actionlint is clean. The real merge_group path can only be exercised once this is on dev.

🤖 Generated with Claude Code

The docs-only skip only looked at pull_request events, so every merge
group ran the full two-platform suite even when nothing but docs/ had
changed. The changes job now also diffs the merge group's base against
its speculative merge commit and skips the heavy jobs when the whole
union is docs-only.

Parser doc pages under docs/content/supported_tools/parsers/ no longer
count as docs-only on either event, because unittests/test_parsers.py
checks them against dojo/tools/.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Maffooch
Maffooch requested a review from blakeaowens as a code owner October 19, 2026 15:43
@Maffooch Maffooch added this to the 3.4.300 milestone Oct 19, 2026
@Maffooch
Maffooch enabled auto-merge October 19, 2026 15:57
@Maffooch Maffooch closed this Oct 19, 2026
auto-merge was automatically disabled October 19, 2026 16:07

Pull request was closed

@Maffooch Maffooch reopened this Oct 19, 2026
@Maffooch
Maffooch enabled auto-merge October 19, 2026 16:38
@Maffooch
Maffooch added this pull request to the merge queue Oct 19, 2026
Merged via the queue into dev with commit 129b4e9 Oct 19, 2026
88 checks passed
@Maffooch
Maffooch deleted the ci/merge-queue-docs-only-skip branch October 19, 2026 16:58
@defectdojo-release-tracker defectdojo-release-tracker Bot modified the milestones: 3.4.300, 3.4.201 Oct 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants