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 sub-context to enable cancellation of checks #61

Merged
merged 3 commits into from
Jan 6, 2017

Conversation

itzg
Copy link
Contributor

@itzg itzg commented Jan 6, 2017

@goru97, @tpboudreau , @GeorgeJahad I was looking at the session go-loops and speculated this change might help for check commit/update logic. Feel free to chop it up or rip it out later if not applicable.

@itzg itzg requested review from rphillips and goru97 January 6, 2017 15:21
@coveralls
Copy link

Coverage Status

Coverage increased (+0.2%) to 66.114% when pulling 5ca31b2 on features/add-check-cancellation into cbcaf49 on master.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.2%) to 66.114% when pulling 34e69e5 on features/add-check-cancellation into cbcaf49 on master.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.2%) to 66.114% when pulling db70f77 on features/add-check-cancellation into cbcaf49 on master.

@@ -151,7 +151,7 @@ func TestHTTPSuccessBodyMatch(t *testing.T) {
"target_resolver":"",
"disabled":false
}`, ts.URL)
check := check.NewCheck([]byte(checkData))
check := check.NewCheck([]byte(checkData), context.Background(), func() {})
Copy link
Contributor

Choose a reason for hiding this comment

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

can we pass a nil instead of func() {}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I worried that even though nothing in our tests currently call Check.Cancel()...a later code change might

Copy link
Contributor

Choose a reason for hiding this comment

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

ah ok

@itzg itzg merged commit 5d9052a into master Jan 6, 2017
@itzg itzg deleted the features/add-check-cancellation branch January 6, 2017 17:59
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.

None yet

3 participants