Skip to content

Commit 1f6a9c3

Browse files
Trottdanielleadams
authored andcommittedDec 13, 2021
test: skip ESLint tests if no Intl
ESLint dependency now requires Intl because it uses regexp unicode character properties. Fixes: #41102 PR-URL: #41105 Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Michaël Zasso <[email protected]> Reviewed-By: Derek Lewis <[email protected]> Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]>
1 parent 1787bfa commit 1f6a9c3

19 files changed

+57
-38
lines changed
 

‎test/parallel/test-eslint-alphabetize-errors.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67
common.skipIfEslintMissing();
78

89
const RuleTester = require('../../tools/node_modules/eslint').RuleTester;

‎test/parallel/test-eslint-async-iife-no-unused-result.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
'use strict';
22
const common = require('../common');
3-
if (!common.hasCrypto)
4-
common.skip('missing crypto');
3+
if ((!common.hasCrypto) || (!common.hasIntl)) {
4+
common.skip('ESLint tests require crypto and Intl');
5+
}
56
common.skipIfEslintMissing();
67

78
const RuleTester = require('../../tools/node_modules/eslint').RuleTester;

‎test/parallel/test-eslint-crypto-check.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67

78
common.skipIfEslintMissing();
89

‎test/parallel/test-eslint-documented-errors.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67
common.skipIfEslintMissing();
78

89
const RuleTester = require('../../tools/node_modules/eslint').RuleTester;

‎test/parallel/test-eslint-duplicate-requires.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67

78
common.skipIfEslintMissing();
89

‎test/parallel/test-eslint-eslint-check.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67

78
common.skipIfEslintMissing();
89

‎test/parallel/test-eslint-inspector-check.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67
common.skipIfEslintMissing();
78

89
const RuleTester = require('../../tools/node_modules/eslint').RuleTester;

‎test/parallel/test-eslint-lowercase-name-for-primitive.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67

78
common.skipIfEslintMissing();
89

‎test/parallel/test-eslint-no-array-destructuring.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67

78
common.skipIfEslintMissing();
89

‎test/parallel/test-eslint-no-unescaped-regexp-dot.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67

78
common.skipIfEslintMissing();
89

‎test/parallel/test-eslint-non-ascii-character.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67

78
common.skipIfEslintMissing();
89

‎test/parallel/test-eslint-prefer-assert-iferror.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67

78
common.skipIfEslintMissing();
89

‎test/parallel/test-eslint-prefer-assert-methods.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67

78
common.skipIfEslintMissing();
89

‎test/parallel/test-eslint-prefer-common-mustnotcall.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67

78
common.skipIfEslintMissing();
89

‎test/parallel/test-eslint-prefer-common-mustsucceed.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67

78
common.skipIfEslintMissing();
89

‎test/parallel/test-eslint-prefer-primordials.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67

78
common.skipIfEslintMissing();
89

‎test/parallel/test-eslint-prefer-util-format-errors.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,9 @@
33
/* eslint-disable no-template-curly-in-string */
44

55
const common = require('../common');
6-
if (!common.hasCrypto)
7-
common.skip('missing crypto');
6+
if ((!common.hasCrypto) || (!common.hasIntl)) {
7+
common.skip('ESLint tests require crypto and Intl');
8+
}
89

910
common.skipIfEslintMissing();
1011

‎test/parallel/test-eslint-require-common-first.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67

78
common.skipIfEslintMissing();
89

‎test/parallel/test-eslint-required-modules.js

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
'use strict';
22

33
const common = require('../common');
4-
if (!common.hasCrypto)
5-
common.skip('missing crypto');
4+
if ((!common.hasCrypto) || (!common.hasIntl)) {
5+
common.skip('ESLint tests require crypto and Intl');
6+
}
67

78
common.skipIfEslintMissing();
89

0 commit comments

Comments
 (0)
Please sign in to comment.