Commit b1a2d6e8 authored by Brad Fitzpatrick's avatar Brad Fitzpatrick

http2: speed up TestTransportFlowControl in short mode

Updates golang/go#18273

Change-Id: I2e7589d070a2953972bc8456d572edd616525266
Reviewed-on: https://go-review.googlesource.com/34271
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: 's avatarTom Bergan <tombergan@google.com>
parent 3d9a20a7
...@@ -2073,10 +2073,11 @@ func TestTransportHandlerBodyClose(t *testing.T) { ...@@ -2073,10 +2073,11 @@ func TestTransportHandlerBodyClose(t *testing.T) {
// https://golang.org/issue/15930 // https://golang.org/issue/15930
func TestTransportFlowControl(t *testing.T) { func TestTransportFlowControl(t *testing.T) {
const ( const bufLen = 64 << 10
total = 100 << 20 // 100MB var total int64 = 100 << 20 // 100MB
bufLen = 1 << 16 if testing.Short() {
) total = 10 << 20
}
var wrote int64 // updated atomically var wrote int64 // updated atomically
st := newServerTester(t, func(w http.ResponseWriter, r *http.Request) { st := newServerTester(t, func(w http.ResponseWriter, r *http.Request) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment