[ruby/prism] Do not rely on RUBY_VERSION being consistent

https://github.com/ruby/prism/commit/34428946db
This commit is contained in:
Kevin Newton 2025-10-16 10:37:42 -04:00 committed by git
parent a8a8f1c20e
commit 68f45a6da7

View File

@ -146,10 +146,6 @@ module Prism
else
assert_raise(CurrentVersionError) { Prism.parse_success?("1 + 1", version: "current") }
end
version = RUBY_VERSION.split(".").tap { |segments| segments[0] = segments[0].succ }.join(".")
assert_includes CurrentVersionError.new(version).message, "unknown"
assert_includes CurrentVersionError.new("2.7").message, "minimum"
end
def test_scopes