-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Test suite fails when the host RubyGems are configured via operating_system.rb #4446
Comments
Just FTR, the best thing would actually be if the |
The issue about The remaining issue maybe was fixed by #4384? Regarding |
I have found workaround:
That is faking SimpleCov availability, therefore the whole RubyGems loading machinery is never triggered, because the original Ruby
This ^^ is Bundler change while I am dealing with RubyGems.
I don't have cycles to try to remove it. I'd be just happy if the take away is that this is not good practice. |
No I did not. I spoke too early 😿 |
So this needs also |
Ok, here is the final version:
|
Ups, closed just accidentally. |
It sounds like a workaround was found and I'm not sure what we should be changing on our side, so I'll close this. |
This is what I proposed:
Really, I don't think it is good idea to let the code which is tested fiddle with the load path. That is not robust. That is what the workaround avoids. This circles back to the |
Feel free to propose any changes you see fit. |
Oh, sorry, so what you are proposing is #4440? That was rejected, unfortunately. If you have other improvements to suggest though, feel free to create a PR. |
I am observing following test failures on Fedora:
The issue here is that Fedora is using
operating_system.rb
to configure the gem locations. Unfortunately, the test suite fails on various places with that configuration (66 failures, 26 errors). Trying to workaround the issue, I'm placing the emptyoperating_system.rb
into the upstream sources:This mostly helps, but leaves the error behind. The reason is that
Gem::StubSpecification#missing_extensions?
cannot find thegem.build_complete
:rubygems/lib/rubygems/stub_specification.rb
Lines 143 to 149 in 8b28c00
So far, I have not figured out how to fix/workaround this issue other then disable the failing test cases. The right solution IMO would be if the test suite does not rely on RubyGems populating the load path. Other nice thing would be if
RubyGems::TestCase
would not require Simplecov.Anecdotally, there should be similar issues reported also for Psych and io-console and possibly other gems. They are not, but I think seems they are going to pop up soon
The text was updated successfully, but these errors were encountered: