Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 4b89ec4

Browse filesBrowse files
aduh95MylesBorins
authored andcommitted
benchmark: add trailing commas in benchmark/http
PR-URL: #46609 Reviewed-By: Darshan Sen <raisinten@gmail.com> Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Moshe Atlow <moshe@atlow.co.il>
1 parent c0983cf commit 4b89ec4
Copy full SHA for 4b89ec4
Expand file treeCollapse file tree

14 files changed

+18
-19
lines changed
Open diff view settings
Collapse file

‎benchmark/.eslintrc.yaml‎

Copy file name to clipboardExpand all lines: benchmark/.eslintrc.yaml
-1Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ rules:
99

1010
overrides:
1111
- files:
12-
- http/*.js
1312
- path/*.js
1413
rules:
1514
comma-dangle: [error, {
Collapse file

‎benchmark/http/bench-parser.js‎

Copy file name to clipboardExpand all lines: benchmark/http/bench-parser.js
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ const common = require('../common');
44

55
const bench = common.createBenchmark(main, {
66
len: [4, 8, 16, 32],
7-
n: [1e5]
7+
n: [1e5],
88
}, {
9-
flags: ['--expose-internals', '--no-warnings']
9+
flags: ['--expose-internals', '--no-warnings'],
1010
});
1111

1212
function main({ len, n }) {
Collapse file

‎benchmark/http/check_invalid_header_char.js‎

Copy file name to clipboardExpand all lines: benchmark/http/check_invalid_header_char.js
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ const groupedInputs = {
2323

2424
// Put it here so the benchmark result lines will not be super long.
2525
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'],
2727
};
2828

2929
const inputs = [
Collapse file

‎benchmark/http/chunked.js‎

Copy file name to clipboardExpand all lines: benchmark/http/chunked.js
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ const bench = common.createBenchmark(main, {
1414
n: [1, 4, 8, 16],
1515
len: [1, 64, 256],
1616
c: [100],
17-
duration: 5
17+
duration: 5,
1818
});
1919

2020
function main({ len, n, c, duration }) {
Collapse file

‎benchmark/http/client-request-body.js‎

Copy file name to clipboardExpand all lines: benchmark/http/client-request-body.js
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ const bench = common.createBenchmark(main, {
88
dur: [5],
99
type: ['asc', 'utf', 'buf'],
1010
len: [32, 256, 1024],
11-
method: ['write', 'end']
11+
method: ['write', 'end'],
1212
});
1313

1414
function main({ dur, len, type, method }) {
@@ -33,7 +33,7 @@ function main({ dur, len, type, method }) {
3333
agent: new http.Agent({ maxSockets: 1 }),
3434
host: '127.0.0.1',
3535
path: '/',
36-
method: 'POST'
36+
method: 'POST',
3737
};
3838

3939
const server = http.createServer((req, res) => {
Collapse file

‎benchmark/http/cluster.js‎

Copy file name to clipboardExpand all lines: benchmark/http/cluster.js
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ function main({ type, len, c, duration }) {
3434
bench.http({
3535
path: path,
3636
connections: c,
37-
duration
37+
duration,
3838
}, () => {
3939
w1.destroy();
4040
w2.destroy();
Collapse file

‎benchmark/http/create-clientrequest.js‎

Copy file name to clipboardExpand all lines: benchmark/http/create-clientrequest.js
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ const bench = common.createBenchmark(main, {
1111
// Use 'url' to avoid name clash with other http benchmark
1212
url: types.concat(['wpt']),
1313
arg: ['URL', 'string', 'options'],
14-
e: [1]
14+
e: [1],
1515
});
1616

1717
function noop() {}
@@ -25,7 +25,7 @@ function main({ url: type, arg, e }) {
2525
switch (arg) {
2626
case 'options': {
2727
const options = data.map((i) => ({
28-
path: new URL(i).path, createConnection: noop
28+
path: new URL(i).path, createConnection: noop,
2929
}));
3030
bench.start();
3131
for (let i = 0; i < len; i++) {
Collapse file

‎benchmark/http/end-vs-write-end.js‎

Copy file name to clipboardExpand all lines: benchmark/http/end-vs-write-end.js
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ const bench = common.createBenchmark(main, {
1515
len: [64 * 1024, 128 * 1024, 256 * 1024, 1024 * 1024],
1616
c: [100],
1717
method: ['write', 'end'],
18-
duration: 5
18+
duration: 5,
1919
});
2020

2121
function main({ len, type, method, c, duration }) {
Collapse file

‎benchmark/http/headers.js‎

Copy file name to clipboardExpand all lines: benchmark/http/headers.js
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ const http = require('http');
66
const bench = common.createBenchmark(main, {
77
n: [10, 600],
88
len: [1, 100],
9-
duration: 5
9+
duration: 5,
1010
});
1111

1212
function main({ len, n, duration }) {
Collapse file

‎benchmark/http/http_server_for_chunky_client.js‎

Copy file name to clipboardExpand all lines: benchmark/http/http_server_for_chunky_client.js
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ tmpdir.refresh();
1515
const server = http.createServer({ maxHeaderSize: 64000 }, (req, res) => {
1616
const headers = {
1717
'content-type': 'text/plain',
18-
'content-length': '2'
18+
'content-length': '2',
1919
};
2020
res.writeHead(200, headers);
2121
res.end('ok');
@@ -28,7 +28,7 @@ server.listen(PIPE);
2828

2929
const child = fork(
3030
`${__dirname}/_chunky_http_client.js`,
31-
process.argv.slice(2)
31+
process.argv.slice(2),
3232
);
3333
child.on('message', (data) => {
3434
if (data.type === 'report') {

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.