Fix spec for ruby-4-2