| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 65b877d commit 9b0d503
14 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -9,7 +9,6 @@ rules: | |||
| 9 | 9 | ||
| 10 | 10 | overrides: | |
| 11 | 11 | - files: | |
| 12 | - - http/*.js | ||
| 13 | 12 | - path/*.js | |
| 14 | 13 | rules: | |
| 15 | 14 | comma-dangle: [error, { | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -4,9 +4,9 @@ const common = require('../common'); | |||
| 4 | 4 | ||
| 5 | 5 | const bench = common.createBenchmark(main, { | |
| 6 | 6 | len: [4, 8, 16, 32], | |
| 7 | - n: [1e5] | ||
| 7 | + n: [1e5], | ||
| 8 | 8 | }, { | |
| 9 | - flags: ['--expose-internals', '--no-warnings'] | ||
| 9 | + flags: ['--expose-internals', '--no-warnings'], | ||
| 10 | 10 | }); | |
| 11 | 11 | ||
| 12 | 12 | function main({ len, n }) { | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -23,7 +23,7 @@ const groupedInputs = { | |||
| 23 | 23 | ||
| 24 | 24 | // Put it here so the benchmark result lines will not be super long. | |
| 25 | 25 | LONG_AND_INVALID: ['Here is a value that is really a folded header ' + | |
| 26 | - 'value\r\n this should be supported, but it is not currently'] | ||
| 26 | + 'value\r\n this should be supported, but it is not currently'], | ||
| 27 | 27 | }; | |
| 28 | 28 | ||
| 29 | 29 | const inputs = [ | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -14,7 +14,7 @@ const bench = common.createBenchmark(main, { | |||
| 14 | 14 | n: [1, 4, 8, 16], | |
| 15 | 15 | len: [1, 64, 256], | |
| 16 | 16 | c: [100], | |
| 17 | - duration: 5 | ||
| 17 | + duration: 5, | ||
| 18 | 18 | }); | |
| 19 | 19 | ||
| 20 | 20 | function main({ len, n, c, duration }) { | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -8,7 +8,7 @@ const bench = common.createBenchmark(main, { | |||
| 8 | 8 | dur: [5], | |
| 9 | 9 | type: ['asc', 'utf', 'buf'], | |
| 10 | 10 | len: [32, 256, 1024], | |
| 11 | - method: ['write', 'end'] | ||
| 11 | + method: ['write', 'end'], | ||
| 12 | 12 | }); | |
| 13 | 13 | ||
| 14 | 14 | function main({ dur, len, type, method }) { | |
@@ -33,7 +33,7 @@ function main({ dur, len, type, method }) { | |||
| 33 | 33 | agent: new http.Agent({ maxSockets: 1 }), | |
| 34 | 34 | host: '127.0.0.1', | |
| 35 | 35 | path: '/', | |
| 36 | - method: 'POST' | ||
| 36 | + method: 'POST', | ||
| 37 | 37 | }; | |
| 38 | 38 | ||
| 39 | 39 | const server = http.createServer((req, res) => { | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -34,7 +34,7 @@ function main({ type, len, c, duration }) { | |||
| 34 | 34 | bench.http({ | |
| 35 | 35 | path: path, | |
| 36 | 36 | connections: c, | |
| 37 | - duration | ||
| 37 | + duration, | ||
| 38 | 38 | }, () => { | |
| 39 | 39 | w1.destroy(); | |
| 40 | 40 | w2.destroy(); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -11,7 +11,7 @@ const bench = common.createBenchmark(main, { | |||
| 11 | 11 | // Use 'url' to avoid name clash with other http benchmark | |
| 12 | 12 | url: types.concat(['wpt']), | |
| 13 | 13 | arg: ['URL', 'string', 'options'], | |
| 14 | - e: [1] | ||
| 14 | + e: [1], | ||
| 15 | 15 | }); | |
| 16 | 16 | ||
| 17 | 17 | function noop() {} | |
@@ -25,7 +25,7 @@ function main({ url: type, arg, e }) { | |||
| 25 | 25 | switch (arg) { | |
| 26 | 26 | case 'options': { | |
| 27 | 27 | const options = data.map((i) => ({ | |
| 28 | - path: new URL(i).path, createConnection: noop | ||
| 28 | + path: new URL(i).path, createConnection: noop, | ||
| 29 | 29 | })); | |
| 30 | 30 | bench.start(); | |
| 31 | 31 | for (let i = 0; i < len; i++) { | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -15,7 +15,7 @@ const bench = common.createBenchmark(main, { | |||
| 15 | 15 | len: [64 * 1024, 128 * 1024, 256 * 1024, 1024 * 1024], | |
| 16 | 16 | c: [100], | |
| 17 | 17 | method: ['write', 'end'], | |
| 18 | - duration: 5 | ||
| 18 | + duration: 5, | ||
| 19 | 19 | }); | |
| 20 | 20 | ||
| 21 | 21 | function main({ len, type, method, c, duration }) { | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -6,7 +6,7 @@ const http = require('http'); | |||
| 6 | 6 | const bench = common.createBenchmark(main, { | |
| 7 | 7 | n: [10, 600], | |
| 8 | 8 | len: [1, 100], | |
| 9 | - duration: 5 | ||
| 9 | + duration: 5, | ||
| 10 | 10 | }); | |
| 11 | 11 | ||
| 12 | 12 | function main({ len, n, duration }) { | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -15,7 +15,7 @@ tmpdir.refresh(); | |||
| 15 | 15 | const server = http.createServer({ maxHeaderSize: 64000 }, (req, res) => { | |
| 16 | 16 | const headers = { | |
| 17 | 17 | 'content-type': 'text/plain', | |
| 18 | - 'content-length': '2' | ||
| 18 | + 'content-length': '2', | ||
| 19 | 19 | }; | |
| 20 | 20 | res.writeHead(200, headers); | |
| 21 | 21 | res.end('ok'); | |
@@ -28,7 +28,7 @@ server.listen(PIPE); | |||
| 28 | 28 | ||
| 29 | 29 | const child = fork( | |
| 30 | 30 | `${__dirname}/_chunky_http_client.js`, | |
| 31 | - process.argv.slice(2) | ||
| 31 | + process.argv.slice(2), | ||
| 32 | 32 | ); | |
| 33 | 33 | child.on('message', (data) => { | |
| 34 | 34 | if (data.type === 'report') { | |
| Back | FazBrowse Home | New Git URL |
0 commit comments