Skip to content

test_bot: avoid deferring when only running dependent tests#21672

Merged
MikeMcQuaid merged 1 commit intomainfrom
test-bot-avoid-deferring
Mar 6, 2026
Merged

test_bot: avoid deferring when only running dependent tests#21672
MikeMcQuaid merged 1 commit intomainfrom
test-bot-avoid-deferring

Conversation

@cho-m
Copy link
Copy Markdown
Member

@cho-m cho-m commented Mar 6, 2026

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same change?
  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your changes? Here's an example.
  • Have you successfully run brew lgtm (style, typechecking and tests) with your changes locally?

  • AI was used to generate or assist with generating this PR. Please specify below how you used AI to help you, and what steps you have taken to manually verify the changes.

This avoids issue of accidentally skipping some dependent tests.

For example, when lua and luarocks were modified in same PR, some direct dependents like luacheck got skipped as:

  1. lua dependents were deferred to be handled by luarocks
  2. luarocks dependents were skipped as build-only dependency

The defer logic is still needed if test-bot runs both formulae and dependent tests together to make sure bottles exist before tests.

This avoids issue of accidentally skipping some dependent tests.

For example, when `lua` and `luarocks` were modified in same PR,
some direct dependents like `luacheck` got skipped as:

1. `lua` dependents were deferred to be handled by `luarocks`
2. `luarocks` dependents were skipped as build-only dependency

The defer logic is still needed if test-bot runs both formulae and
dependent tests together to make sure bottles exist before tests.
Copilot AI review requested due to automatic review settings March 6, 2026 00:20
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adjusts brew test-bot dependent-selection behavior to avoid incorrectly deferring/skipping dependents when running only the dependents phase, preventing missed dependent tests in multi-formula PRs.

Changes:

  • Skip the “defer dependents until later” filtering when --only-formulae-dependents is used.
  • Preserve existing deferral behavior for runs that include building formulae alongside dependent testing.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Copy Markdown
Member

@MikeMcQuaid MikeMcQuaid left a comment

Choose a reason for hiding this comment

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

Thanks again @cho-m!

@MikeMcQuaid MikeMcQuaid added this pull request to the merge queue Mar 6, 2026
Merged via the queue into main with commit 8d0c8ae Mar 6, 2026
42 checks passed
@MikeMcQuaid MikeMcQuaid deleted the test-bot-avoid-deferring branch March 6, 2026 08:29
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.

4 participants