Open
Conversation
bbb8d49 to
6234d63
Compare
Member
Author
|
Ended up uncovering an issue in the RBS crate ruby/rbs#2859 |
Morriar
reviewed
Mar 2, 2026
|
|
||
| def test_index_workspace_includes_rbs_core_definitions | ||
| # Ensure the `rbs` gem is installed on CI | ||
| Gem.install("rbs") if ENV["CI"] |
Contributor
There was a problem hiding this comment.
I'm wondering if Gem.install in a test is the right approach here — it's a side effect that modifies the system state during a test run.
Should we add it to the tests group in the Gemfile instead?
Another solution is to only install the gem in the context as we do in Tapioca: https://github.com/Shopify/tapioca/blob/main/spec/tapioca/cli/gem_spec.rb#L120-L125
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.

Now that we have some RBS indexing, we can automatically include the RBS paths for
coreandstdlibto get the complete data when usingindex_workspace. In the future, we may want to ship with a fully indexed RBS cache, but for now let's just include the paths.One design note: we should not require that
rbsbe on the bundle. Instead of usingGem::Specification.findorGem.find_files(both of which are scoped to the bundle), I just searchedGem.pathmanually for the latestrbsinstallation.