diff --git a/benchmarks/benchmark.js b/benchmarks/benchmark.js index 9aed5d5607b..c9ca0bd2bab 100644 --- a/benchmarks/benchmark.js +++ b/benchmarks/benchmark.js @@ -283,17 +283,14 @@ if (process.env.PORT) { } const gotOptions = { - url: dest.url, method: 'GET', agent: { http: gotAgent - }, - // avoid body processing - isStream: true + } } experiments.got = () => { return makeParallelRequests(resolve => { - got(gotOptions).pipe(new Writable({ + got.stream(dest.url, gotOptions).pipe(new Writable({ write (chunk, encoding, callback) { callback() } diff --git a/benchmarks/post-benchmark.js b/benchmarks/post-benchmark.js index 847903a6b0a..c58fe342c63 100644 --- a/benchmarks/post-benchmark.js +++ b/benchmarks/post-benchmark.js @@ -299,19 +299,16 @@ if (process.env.PORT) { } const gotOptions = { - url: dest.url, method: 'POST', headers, agent: { http: gotAgent }, - // avoid body processing - isStream: true, body: data } experiments.got = () => { return makeParallelRequests(resolve => { - got(gotOptions).pipe(new Writable({ + got.stream(dest.url, gotOptions).pipe(new Writable({ write (chunk, encoding, callback) { callback() }