Skip to content

Commit

Permalink
Merge pull request etcd-io#10542 from johncming/usecancel
Browse files Browse the repository at this point in the history
integration: use cancel instead of close.
  • Loading branch information
xiang90 authored Mar 19, 2019
2 parents ec1cbce + 9750983 commit 2d9b32d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions integration/v3_alarm_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,8 @@ func TestV3StorageQuotaApply(t *testing.T) {
}
}

ctx, close := context.WithTimeout(context.TODO(), RequestWaitTimeout)
defer close()
ctx, cancel := context.WithTimeout(context.TODO(), RequestWaitTimeout)
defer cancel()

// small quota machine should reject put
if _, err := kvc0.Put(ctx, &pb.PutRequest{Key: key, Value: smallbuf}); err == nil {
Expand Down

0 comments on commit 2d9b32d

Please sign in to comment.