Skip to content

Update specs for it parameter in proc for Ruby 4.0 - #1320

Merged
eregon merged 1 commit into
ruby:masterfrom
herwinw:ruby4_it
Jan 4, 2026
Merged

Update specs for it parameter in proc for Ruby 4.0#1320
eregon merged 1 commit into
ruby:masterfrom
herwinw:ruby4_it

Conversation

@herwinw

@herwinw herwinw commented Jan 4, 2026

Copy link
Copy Markdown
Member

The behaviour has changed in Ruby 4.0.
As a bonus: fix a typo: paramater => parameter

The behaviour has changed in Ruby 4.0.
As a bonus: fix a typo: paramater => parameter
@herwinw

herwinw commented Jan 4, 2026

Copy link
Copy Markdown
Member Author

This was a change written before 4.0 ( #1224), it had to be updated or it will break the specs with Ruby 4.0.

@eregon

eregon commented Jan 4, 2026

Copy link
Copy Markdown
Member

Ah yes I noticed the same in

ruby_version_is ""..."4.0" do
proc { it }.parameters.should == [[:opt, nil]]
end
ruby_version_is "4.0" do
proc { it }.parameters.should == [[:opt]]
end

It's actually duplicated specs, not sure which one(s) we should keep but anyway let's merge this.

@eregon
eregon merged commit dc31673 into ruby:master Jan 4, 2026
13 checks passed
@herwinw
herwinw deleted the ruby4_it branch January 5, 2026 14:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants