Skip to content

Commit 339d220

Browse files
sam-githubjasnell
authored andcommitted
test: rearrange inspector headers into convention
Test guide describes a conventional layout for test headers, review inspector tests and reorganize to follow the convention. PR-URL: #13428 Reviewed-By: Refael Ackermann <[email protected]> Reviewed-By: Colin Ihrig <[email protected]> Reviewed-By: Gibson Fahnestock <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: James M Snell <[email protected]>
1 parent 6aeb555 commit 339d220

8 files changed

+16
-5
lines changed

‎test/inspector/test-inspector-debug-brk.js‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
'use strict';
22
constcommon=require('../common');
3+
34
common.skipIfInspectorDisabled();
5+
46
constassert=require('assert');
57
consthelper=require('./inspector-helper.js');
68

‎test/inspector/test-inspector-ip-detection.js‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
'use strict';
22
constcommon=require('../common');
3+
34
common.skipIfInspectorDisabled();
45

56
constassert=require('assert');

‎test/inspector/test-inspector-port-zero-cluster.js‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
// Flags: --inspect=0
22
'use strict';
3-
43
constcommon=require('../common');
4+
55
common.skipIfInspectorDisabled();
6+
67
constassert=require('assert');
78
constcluster=require('cluster');
89

‎test/inspector/test-inspector-port-zero.js‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
'use strict';
2-
32
const{ mustCall, skipIfInspectorDisabled }=require('../common');
3+
44
skipIfInspectorDisabled();
5+
56
constassert=require('assert');
67
const{URL}=require('url');
78
const{ spawn }=require('child_process');

‎test/inspector/test-inspector-stops-no-file.js‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
'use strict';
22
require('../common');
3+
34
constspawn=require('child_process').spawn;
45

56
constchild=spawn(process.execPath,

‎test/inspector/test-inspector.js‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
'use strict';
22
constcommon=require('../common');
3+
34
common.skipIfInspectorDisabled();
5+
46
constassert=require('assert');
57
consthelper=require('./inspector-helper.js');
68

‎test/parallel/test-cluster-inspector-debug-port.js‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
'use strict';
22
// Flags: --inspect={PORT}
33
constcommon=require('../common');
4+
45
common.skipIfInspectorDisabled();
6+
57
constassert=require('assert');
68
constcluster=require('cluster');
79
constdebuggerPort=common.PORT;

‎test/parallel/test-inspector-invalid-args.js‎

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,12 @@
11
'use strict';
2+
constcommon=require('../common');
3+
4+
common.skipIfInspectorDisabled();
5+
26
constassert=require('assert');
37
constexecFile=require('child_process').execFile;
48
constpath=require('path');
59

6-
constcommon=require('../common');
7-
common.skipIfInspectorDisabled();
8-
910
constmainScript=path.join(common.fixturesDir,'loop.js');
1011
constexpected=
1112
'`node --debug` and `node --debug-brk` are invalid. '+

0 commit comments

Comments
(0)