sorbet: Bump more OS-specific tests to higher typed levels - #23575
Merged
Conversation
issyl0
force-pushed
the
sorbet-os-two-errors
branch
from
August 19, 2026 21:44
edde7e6 to
d9aaef5
Compare
issyl0
force-pushed
the
sorbet-os-two-errors
branch
from
August 19, 2026 21:45
d9aaef5 to
a287dcd
Compare
issyl0
marked this pull request as ready for review
August 19, 2026 22:17
Contributor
There was a problem hiding this comment.
Pull request overview
This PR increases Sorbet type coverage in OS-specific RSpec tests by bumping selected spec files from typed: false to typed: true, ensuring these tests typecheck under stricter settings.
Changes:
- Promote
Library/Homebrew/test/os/mac/ffi/native_library_spec.rbtotyped: trueand adjust the test module’s singleton method definition to satisfy Sorbet typing (viaT.bindanddefine_singleton_method). - Promote
Library/Homebrew/test/os/linux/ld_spec.rbtotyped: trueand refactor the temporary directory setup from a captured local variable to an RSpeclet.
Show a summary per file
| File | Description |
|---|---|
| Library/Homebrew/test/os/mac/ffi/native_library_spec.rb | Raises Sorbet strictness for the macOS FFI native library spec and updates method definition/binding for typechecking. |
| Library/Homebrew/test/os/linux/ld_spec.rb | Raises Sorbet strictness for the Linux ld spec and modernises tmpdir setup using let. |
Review details
💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.
- Files reviewed: 2/2 changed files
- Comments generated: 0
- Review effort level: Lite
issyl0
marked this pull request as draft
August 19, 2026 22:31
- Define the temporary ld.so configuration directory as an RSpec let so setup, examples and cleanup share a non-nil Pathname. - Bind the anonymous native-library module after extending it, and use a singleton-method block that preserves the extended receiver type.
issyl0
force-pushed
the
sorbet-os-two-errors
branch
from
August 19, 2026 23:29
a287dcd to
642ed21
Compare
MikeMcQuaid
marked this pull request as ready for review
August 20, 2026 07:40
MikeMcQuaid
approved these changes
Aug 20, 2026
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.
brewcommands to reproduce the bug?brew lgtm(style, typechecking and tests) locally?Claude Code CLI, Claude Opus 5 (High reasoning, Ultracode was too intense 🤯), with human prompting, review and tweaks.
typed: true, because that's a thing we can do.gh stackbecause I wanted to try them out on a real chain of changes.