Move simplecov
config into rails_helper
#30302
Merged
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.
Extracted from #30284
I had previously done the extraction into the
.simplecov
file, which seemed harmless at the time, but introduced a subtle load order bug that I finally hit on that flatware PR.When you require
simplecov
, it checks if the.simplecov
file exists, and if it does, immediately loads/runs it. This is fine when you do that once, but if you have multiple places that need to do different portion of the config (the flatware PR has one place for flatware to interact with theat_fork
setting of simplecov and other place for the core/regular config) it means you've lost control of when to do which things.So, this is a few changes:
I'm curious to confirm the codecov results on this one by itself - but also this felt like a good extraction from the flatware PR to keep that one focused on just adding flatware and not on unrelated simplecov config.