acme: in TestFetchCertCancel, do not reply before the cancellation propagates
Fixes golang/go#44611
Trust: Bryan Mills
Run-TryBot: Bryan Mills
TryBot-Result: Gopher Robot
@@ -975,6 +975,7 @@ func TestFetchCertRetry(t *testing.T) {
func TestFetchCertCancel(t *testing.T) {
ts := httptest.NewServer(http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
+ <-r.Context().Done()
w.Header().Set("Retry-After", "0")
w.WriteHeader(http.StatusBadRequest)
}))
