Skip to content

Commit

Permalink
test: rearrange inspector headers into convention
Browse files Browse the repository at this point in the history
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 <refack@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
  • Loading branch information
sam-github authored and jasnell committed Jun 5, 2017
1 parent 6aeb555 commit 339d220
Show file tree
Hide file tree
Showing 8 changed files with 16 additions and 5 deletions.
2 changes: 2 additions & 0 deletions test/inspector/test-inspector-debug-brk.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
'use strict';
const common = require('../common');

common.skipIfInspectorDisabled();

const assert = require('assert');
const helper = require('./inspector-helper.js');

Expand Down
1 change: 1 addition & 0 deletions test/inspector/test-inspector-ip-detection.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
'use strict';
const common = require('../common');

common.skipIfInspectorDisabled();

const assert = require('assert');
Expand Down
3 changes: 2 additions & 1 deletion test/inspector/test-inspector-port-zero-cluster.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
// Flags: --inspect=0
'use strict';

const common = require('../common');

common.skipIfInspectorDisabled();

const assert = require('assert');
const cluster = require('cluster');

Expand Down
3 changes: 2 additions & 1 deletion test/inspector/test-inspector-port-zero.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
'use strict';

const { mustCall, skipIfInspectorDisabled } = require('../common');

skipIfInspectorDisabled();

const assert = require('assert');
const { URL } = require('url');
const { spawn } = require('child_process');
Expand Down
1 change: 1 addition & 0 deletions test/inspector/test-inspector-stops-no-file.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
'use strict';
require('../common');

const spawn = require('child_process').spawn;

const child = spawn(process.execPath,
Expand Down
2 changes: 2 additions & 0 deletions test/inspector/test-inspector.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
'use strict';
const common = require('../common');

common.skipIfInspectorDisabled();

const assert = require('assert');
const helper = require('./inspector-helper.js');

Expand Down
2 changes: 2 additions & 0 deletions test/parallel/test-cluster-inspector-debug-port.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
'use strict';
// Flags: --inspect={PORT}
const common = require('../common');

common.skipIfInspectorDisabled();

const assert = require('assert');
const cluster = require('cluster');
const debuggerPort = common.PORT;
Expand Down
7 changes: 4 additions & 3 deletions test/parallel/test-inspector-invalid-args.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
'use strict';
const common = require('../common');

common.skipIfInspectorDisabled();

const assert = require('assert');
const execFile = require('child_process').execFile;
const path = require('path');

const common = require('../common');
common.skipIfInspectorDisabled();

const mainScript = path.join(common.fixturesDir, 'loop.js');
const expected =
'`node --debug` and `node --debug-brk` are invalid. ' +
Expand Down

0 comments on commit 339d220

Please sign in to comment.