Skip to content

Commit

Permalink
test: remove common.skipIfReportDisabled()
Browse files Browse the repository at this point in the history
The report feature won't ever be disabled moving forward, so
checking for its existence in the tests is no longer needed.

PR-URL: #32242
Fixes: #26293
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: David Carlier <[email protected]>
Reviewed-By: Gireesh Punathil <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Matteo Collina <[email protected]>
  • Loading branch information
cjihrig authored and MylesBorins committed Mar 24, 2020
1 parent 074c3c1 commit 76781bd
Show file tree
Hide file tree
Showing 9 changed files with 1 addition and 15 deletions.
7 changes: 0 additions & 7 deletions test/common/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -553,12 +553,6 @@ function skipIfInspectorDisabled() {
}
}

function skipIfReportDisabled() {
if (!process.config.variables.node_report) {
skip('Diagnostic reporting is disabled');
}
}

function skipIf32Bits() {
if (bits < 64) {
skip('The tested feature is not available in 32bit builds');
Expand Down Expand Up @@ -700,7 +694,6 @@ const common = {
skipIf32Bits,
skipIfEslintMissing,
skipIfInspectorDisabled,
skipIfReportDisabled,
skipIfWorker,

get enoughTestCpu() {
Expand Down
1 change: 0 additions & 1 deletion test/report/test-report-config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// Flags: --experimental-report --report-on-fatalerror --report-on-signal --report-uncaught-exception
'use strict';
const common = require('../common');
common.skipIfReportDisabled();
const assert = require('assert');

common.expectWarning('ExperimentalWarning',
Expand Down
1 change: 0 additions & 1 deletion test/report/test-report-fatal-error.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
'use strict';

const common = require('../common');
common.skipIfReportDisabled();
const assert = require('assert');
// Testcase to produce report on fatal error (javascript heap OOM)
if (process.argv[2] === 'child') {
Expand Down
1 change: 0 additions & 1 deletion test/report/test-report-getreport.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// Flags: --experimental-report
'use strict';
const common = require('../common');
common.skipIfReportDisabled();
const assert = require('assert');
const helper = require('../common/report');

Expand Down
2 changes: 1 addition & 1 deletion test/report/test-report-signal.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
'use strict';
// Test producing a report via signal.
const common = require('../common');
common.skipIfReportDisabled();

if (common.isWindows)
return common.skip('Unsupported on Windows.');

Expand Down
1 change: 0 additions & 1 deletion test/report/test-report-uncaught-exception.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
'use strict';
// Test producing a report on uncaught exception.
const common = require('../common');
common.skipIfReportDisabled();
const assert = require('assert');
const helper = require('../common/report');
const tmpdir = require('../common/tmpdir');
Expand Down
1 change: 0 additions & 1 deletion test/report/test-report-uv-handles.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ const common = require('../common');
if (common.isIBMi)
common.skip('IBMi does not support fs.watch()');

common.skipIfReportDisabled();
if (process.argv[2] === 'child') {
// Exit on loss of parent process
const exit = () => process.exit(2);
Expand Down
1 change: 0 additions & 1 deletion test/report/test-report-worker.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// Flags: --experimental-report
'use strict';
const common = require('../common');
common.skipIfReportDisabled();
const assert = require('assert');
const { Worker } = require('worker_threads');
const { once } = require('events');
Expand Down
1 change: 0 additions & 1 deletion test/report/test-report-writereport.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@

// Test producing a report via API call, using the no-hooks/no-signal interface.
const common = require('../common');
common.skipIfReportDisabled();
const assert = require('assert');
const { spawnSync } = require('child_process');
const fs = require('fs');
Expand Down

0 comments on commit 76781bd

Please sign in to comment.