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

Randomly failing spec #39

Closed
yhirano55 opened this issue Apr 4, 2018 · 3 comments
Closed

Randomly failing spec #39

yhirano55 opened this issue Apr 4, 2018 · 3 comments
Assignees

Comments

@yhirano55
Copy link
Contributor

We have to fix it:

Failures:
  1) BlockingMatcher does not match when a Proc does not block the caller
     Failure/Error: BlockingMatcher.new.matches?(proc { 1 }).should == false
       expected: false
            got: true (using ==)
     # ./spec/matchers/block_caller_spec.rb:11:in `block (2 levels) in <top (required)>'
@eregon
Copy link
Member

eregon commented Apr 4, 2018

I noticed it as well.
I think it's a bug of block_caller.rb.
But I don't understand how it happens, since Thread#status should be "run" for the entire Thread lifetime, and the thread should set blocking to false.
Ah, actually it probably leaves the loop too early as soon as started is set.

@eregon eregon self-assigned this Apr 4, 2018
@eregon eregon closed this as completed in d84d766 Apr 4, 2018
@eregon
Copy link
Member

eregon commented Apr 4, 2018

Thanks for filing the issue, it made me investigate a bit deeper and I found the bug :)
Should be fixed with d84d766.

@yhirano55
Copy link
Contributor Author

Great 👍

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

No branches or pull requests

2 participants