Skip to content

Commit

Permalink
test: skip ESLint tests if no Intl
Browse files Browse the repository at this point in the history
ESLint dependency now requires Intl because it uses regexp unicode
character properties.

Fixes: #41102

PR-URL: #41105
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Derek Lewis <DerekNonGeneric@inf.is>
Reviewed-By: Richard Lau <rlau@redhat.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
  • Loading branch information
Trott authored and danielleadams committed Dec 13, 2021
1 parent 1787bfa commit 1f6a9c3
Show file tree
Hide file tree
Showing 19 changed files with 57 additions and 38 deletions.
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-alphabetize-errors.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}
common.skipIfEslintMissing();

const RuleTester = require('../../tools/node_modules/eslint').RuleTester;
Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-async-iife-no-unused-result.js
@@ -1,7 +1,8 @@
'use strict';
const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}
common.skipIfEslintMissing();

const RuleTester = require('../../tools/node_modules/eslint').RuleTester;
Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-crypto-check.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}

common.skipIfEslintMissing();

Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-documented-errors.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}
common.skipIfEslintMissing();

const RuleTester = require('../../tools/node_modules/eslint').RuleTester;
Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-duplicate-requires.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}

common.skipIfEslintMissing();

Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-eslint-check.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}

common.skipIfEslintMissing();

Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-inspector-check.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}
common.skipIfEslintMissing();

const RuleTester = require('../../tools/node_modules/eslint').RuleTester;
Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-lowercase-name-for-primitive.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}

common.skipIfEslintMissing();

Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-no-array-destructuring.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}

common.skipIfEslintMissing();

Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-no-unescaped-regexp-dot.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}

common.skipIfEslintMissing();

Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-non-ascii-character.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}

common.skipIfEslintMissing();

Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-prefer-assert-iferror.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}

common.skipIfEslintMissing();

Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-prefer-assert-methods.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}

common.skipIfEslintMissing();

Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-prefer-common-mustnotcall.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}

common.skipIfEslintMissing();

Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-prefer-common-mustsucceed.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}

common.skipIfEslintMissing();

Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-prefer-primordials.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}

common.skipIfEslintMissing();

Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-prefer-util-format-errors.js
Expand Up @@ -3,8 +3,9 @@
/* eslint-disable no-template-curly-in-string */

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}

common.skipIfEslintMissing();

Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-require-common-first.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}

common.skipIfEslintMissing();

Expand Down
5 changes: 3 additions & 2 deletions test/parallel/test-eslint-required-modules.js
@@ -1,8 +1,9 @@
'use strict';

const common = require('../common');
if (!common.hasCrypto)
common.skip('missing crypto');
if ((!common.hasCrypto) || (!common.hasIntl)) {
common.skip('ESLint tests require crypto and Intl');
}

common.skipIfEslintMissing();

Expand Down

0 comments on commit 1f6a9c3

Please sign in to comment.