Repository navigation
sorbet: More T.binds in test formula/caveats blocks - #24106
Merged
Merged
Conversation
- More incremental fixes to reduce the number of errors as we progress towards 100% typed tests.
- It's `instance_eval`ed on `DSL::Caveats`, which is where `requires_rosetta` and friends live.
Contributor
There was a problem hiding this comment.
Copilot review overview
🟢 Approval recommended
No unresolved review issues were identified.
Review effort: Lite
Findings: None
What changed in this PR
Improves Sorbet typing across formula and cask DSL test blocks without changing runtime behavior.
Changes:
- Adds
T.bindannotations to formula test blocks. - Types cask caveats block receivers.
- Raises typing strictness for integration coverage and
mktemptests.
| File | Description |
|---|---|
Library/Homebrew/test/vulns/osv_export_spec.rb |
Types formula DSL blocks. |
Library/Homebrew/test/support/helper/integration_coverage.rb |
Enables typed checking. |
Library/Homebrew/test/mktemp_spec.rb |
Raises typing strictness. |
Library/Homebrew/test/formula_installer_spec.rb |
Types formula DSL blocks. |
Library/Homebrew/test/cmd/info_spec.rb |
Types formula DSL blocks. |
Library/Homebrew/test/cli/parser_spec.rb |
Types a formula DSL block. |
Library/Homebrew/test/cask/installer_spec.rb |
Types a formula DSL block. |
Library/Homebrew/cask/dsl.rb |
Types the caveats block receiver. |
💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.
issyl0
enabled auto-merge
September 27, 2026 19:48
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
brew benchmarkresults.brewcommands to reproduce the bug?brew lgtm(style, typechecking and tests) locally?Claude Code (Fable 5, High reasoning) to categorize the remaining Sorbet failures in tests.
typed: true, but it does reduce the number of errors incrementally.