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 534bc82

Browse filesBrowse files
ryzokukenBethGriggs
authored andcommitted
test: name test files appropriately
Rename the tests appropriately alongside mentioning the subsystem. Also, make a few basic changes to make sure the test conforms to the standard test structure. This renames: - test-regress-GH-1531 - test-regress-GH-2245 - test-regress-GH-3238 - test-regress-GH-3542 - test-regress-GH-3739 - test-regress-GH-4256 PR-URL: #19212 Refs: #19105 Refs: https://github.com/nodejs/node/blob/master/doc/guides/writing-tests.md#test-structure Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de> Reviewed-By: James M Snell <jasnell@gmail.com>
1 parent eaabbf4 commit 534bc82
Copy full SHA for 534bc82

File tree

Expand file treeCollapse file tree

6 files changed

+31
-13
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

6 files changed

+31
-13
lines changed
Open diff view settings
Collapse file

‎test/parallel/test-regress-GH-3238.js‎ ‎…parallel/test-cluster-kill-disconnect.js‎test/parallel/test-regress-GH-3238.js renamed to test/parallel/test-cluster-kill-disconnect.js test/parallel/test-regress-GH-3238.js renamed to test/parallel/test-cluster-kill-disconnect.js

Copy file name to clipboardExpand all lines: test/parallel/test-cluster-kill-disconnect.js
+6Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
'use strict';
22
const common = require('../common');
3+
4+
// Check that cluster works perfectly for both `kill` and `disconnect` cases.
5+
// Also take into account that the `disconnect` event may be received after the
6+
// `exit` event.
7+
// https://github.com/nodejs/node/issues/3238
8+
39
const assert = require('assert');
410
const cluster = require('cluster');
511

Collapse file

‎test/parallel/test-regress-GH-2245.js‎ ‎…allel/test-eval-strict-referenceerror.js‎test/parallel/test-regress-GH-2245.js renamed to test/parallel/test-eval-strict-referenceerror.js test/parallel/test-regress-GH-2245.js renamed to test/parallel/test-eval-strict-referenceerror.js

Copy file name to clipboardExpand all lines: test/parallel/test-eval-strict-referenceerror.js
+5-6Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
11
/* eslint-disable strict */
22
require('../common');
3-
const assert = require('assert');
43

5-
/*
6-
In Node.js 0.10, a bug existed that caused strict functions to not capture
7-
their environment when evaluated. When run in 0.10 `test()` fails with a
8-
`ReferenceError`. See https://github.com/nodejs/node/issues/2245 for details.
9-
*/
4+
// In Node.js 0.10, a bug existed that caused strict functions to not capture
5+
// their environment when evaluated. When run in 0.10 `test()` fails with a
6+
// `ReferenceError`. See https://github.com/nodejs/node/issues/2245 for details.
7+
8+
const assert = require('assert');
109

1110
function test() {
1211

Collapse file
+6-3Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,15 @@
11
'use strict';
2-
32
const common = require('../common');
3+
const tmpdir = require('../common/tmpdir');
4+
5+
// This test ensures that fs.existsSync doesn't incorrectly return false.
6+
// (especially on Windows)
7+
// https://github.com/nodejs/node-v0.x-archive/issues/3739
8+
49
const assert = require('assert');
510
const fs = require('fs');
611
const path = require('path');
712

8-
const tmpdir = require('../common/tmpdir');
9-
1013
let dir = path.resolve(tmpdir.path);
1114

1215
// Make sure that the tmp directory is clean
Collapse file

‎test/parallel/test-regress-GH-3542.js‎ ‎…/parallel/test-fs-readfilesync-enoent.js‎test/parallel/test-regress-GH-3542.js renamed to test/parallel/test-fs-readfilesync-enoent.js test/parallel/test-regress-GH-3542.js renamed to test/parallel/test-fs-readfilesync-enoent.js

Copy file name to clipboardExpand all lines: test/parallel/test-fs-readfilesync-enoent.js
+5Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,14 @@
11
'use strict';
22
const common = require('../common');
3+
34
// This test is only relevant on Windows.
45
if (!common.isWindows)
56
common.skip('Windows specific test.');
67

8+
// This test ensures fs.realpathSync works on properly on Windows without
9+
// throwing ENOENT when the path involves a fileserver.
10+
// https://github.com/nodejs/node-v0.x-archive/issues/3542
11+
712
const assert = require('assert');
813
const fs = require('fs');
914
const path = require('path');
Collapse file
+4-4Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
'use strict';
22
const common = require('../common');
33

4-
// This test ensures that a http request callback is called
5-
// when the agent option is set
6-
// See https://github.com/nodejs/node-v0.x-archive/issues/1531
7-
84
if (!common.hasCrypto)
95
common.skip('missing crypto');
106

117
const fixtures = require('../common/fixtures');
128

9+
// This test ensures that a http request callback is called when the agent
10+
// option is set.
11+
// See https://github.com/nodejs/node-v0.x-archive/issues/1531
12+
1313
const https = require('https');
1414

1515
const options = {
Collapse file

‎test/parallel/test-regress-GH-4256.js‎ ‎…parallel/test-process-domain-segfault.js‎test/parallel/test-regress-GH-4256.js renamed to test/parallel/test-process-domain-segfault.js test/parallel/test-regress-GH-4256.js renamed to test/parallel/test-process-domain-segfault.js

Copy file name to clipboardExpand all lines: test/parallel/test-process-domain-segfault.js
+5Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,11 @@
2121

2222
'use strict';
2323
require('../common');
24+
25+
// This test ensures that setting `process.domain` to `null` does not result in
26+
// node crashing with a segfault.
27+
// https://github.com/nodejs/node-v0.x-archive/issues/4256
28+
2429
process.domain = null;
2530
setTimeout(function() {
2631
console.log('this console.log statement should not make node crash');

0 commit comments

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