-
Notifications
You must be signed in to change notification settings - Fork 3
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
Bugfix: pending waiter #497
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! One question and one joke ⬇️
@@ -20,7 +20,7 @@ type ( | |||
) | |||
|
|||
// NewHandler new instance of PendingHandler | |||
func NewHandler(size int) Handler { | |||
func NewHandler() Handler { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
size
does not matter 😉
func TestPendingWaiter(t *testing.T) { | ||
counters := &statistics.ExecutionCounters{} | ||
state := New(context.Background(), "", 120, nil, 1, 1, "", false, counters) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did this simple test break the old one? If so, good! If not it would be a good idea to create such a test.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes I created it as a failing test with old one, and doesn't fail with new implementation
Checklist
Squash commit message
Fixes bug where something added to state.pending after emptying, but before emptying of resthandler.pending would not wait as expected.
Info
Optional informative text (not to be included in commit message) relevant to reviewers.