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

Add specs for Fiber.scheduler and Fiber.set_scheduler #1064

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

herwinw
Copy link
Member

@herwinw herwinw commented Aug 31, 2023

With a few remarks, since I'm not sure about some best practices here.

  • The feature is mentioned in Write specs for new Ruby 3.0 features and changes #823 and assigned to @aardvark179 (at least, I guess that's what the username in front of the item means). I'm not trying to step in line or step on anybody's toes, but this is what I'm currently working on for Natalie, so I kind of needed the specs anyway.
  • I didn't see much use in testing these two methods separately, since you can only set if you've set a scheduler by requesting the scheduler and vice versa (unless you count actually using the scheduler, but that makes it even more complex). I've used a shared spec that combines the tests for them, which passes on the methods that we don't use in the specs. This is totally different from other shared specs (like Hash#include? and Hash#key?) I couldn't really find an example of other intertwined methods, so there might be a more idiomatic way of doing this.

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

Successfully merging this pull request may close these issues.

1 participant