Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix count when enumerable yields multiple values #3591

Merged
merged 2 commits into from Jan 28, 2016

Conversation

@jsyeo
Copy link
Member

@jsyeo jsyeo commented Jan 28, 2016

No description provided.

it "gathers initial args as elements when each yields multiple" do
multi = EnumerableSpecs::YieldsMulti.new
multi.count {|e| e == 1 }.should == 1
context "when each yields multiple" do
Copy link
Member

@YorickPeterse YorickPeterse Jan 28, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We generally use describe instead of context. Also I think "yields multiple values" reads more natural.

Loading

@jsyeo jsyeo force-pushed the jsyeo-count-yield-multi branch from 3e987c7 to 3854fe5 Jan 28, 2016
@jsyeo
Copy link
Member Author

@jsyeo jsyeo commented Jan 28, 2016

This will fix #3554 (comment)

Loading

jsyeo added a commit that referenced this issue Jan 28, 2016
Fix count when enumerable yields multiple values
@jsyeo jsyeo merged commit 36eee9e into rubinius:master Jan 28, 2016
@jsyeo jsyeo deleted the jsyeo-count-yield-multi branch Jan 28, 2016
@ioquatix
Copy link

@ioquatix ioquatix commented Jan 28, 2016

Nice work guys :)

Loading

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants