Allow older rubies (with warning) #52
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.
I use
mspecforbackports.I use it to run recent specs against old rubies that have had features backported.
I am in the process of using
ruby/mspecinstead ofmspecgem because some specs no longer run (in particular becauselambda?helper is new, not sure if there are other reasons).So that the specs run, I need to tell
ruby_version_iswhat the actual target is. There used to beSpecGuard.ruby_version_override=, which as been removed. I can go around that.Also,
mspecrefuses to run older Rubies .. This PR is a small change to allow me to runmspecfrom older versions by turning an error into a warning / or overwrite the method altogether.I imagine that the minimum Ruby requirement is constantly being bumped to minimize support. I'm not sure it is the right approach.
mspecaims to be a simple and minimal implementation ofrspec-like runner so that other Ruby implementation can hope to run it. Eithermspecruns on older rubies (and this bumping is not necessary) or it doesn't (and this may make alternate implementations harder). FWIW, currentmasterappears to run (at least for my purposes) in Ruby 2.1 (in Ruby 2.0 theprivate defdon't work, I don't know if there are other actual issues) Hopefully this can be the case for some years to come...