diff options
author | Myles Borins <mylesborins@google.com> | 2018-02-15 18:47:10 -0500 |
---|---|---|
committer | James M Snell <jasnell@gmail.com> | 2018-02-16 15:54:56 -0800 |
commit | 1fd69872e6c4d2dd8127560ae078b4cbf8b7badb (patch) | |
tree | e745ed55940dc1c8da3f1bd4cb65e828456c7052 /test/parallel/test-eslint-no-unescaped-regexp-dot.js | |
parent | 6ab288f3b817197631f23dd858b1b622d80dab27 (diff) | |
download | android-node-v8-1fd69872e6c4d2dd8127560ae078b4cbf8b7badb.tar.gz android-node-v8-1fd69872e6c4d2dd8127560ae078b4cbf8b7badb.tar.bz2 android-node-v8-1fd69872e6c4d2dd8127560ae078b4cbf8b7badb.zip |
test: add common.skipIfEslintMissing
We've added a number of tests that hook into ESLint which can error
when running the test suite with the distributed tarball. This PR
adds a new test helper `common.skipIfEslintMissing` and will skip
remaining tests in a file when `ESLint` is not available at
`tools/node_modules/eslint`
PR-URL: https://github.com/nodejs/node/pull/18807
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Yuta Hiroto <hello@about-hiroppy.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Diffstat (limited to 'test/parallel/test-eslint-no-unescaped-regexp-dot.js')
-rw-r--r-- | test/parallel/test-eslint-no-unescaped-regexp-dot.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/parallel/test-eslint-no-unescaped-regexp-dot.js b/test/parallel/test-eslint-no-unescaped-regexp-dot.js index 38a9f3efcc..e6f09291b0 100644 --- a/test/parallel/test-eslint-no-unescaped-regexp-dot.js +++ b/test/parallel/test-eslint-no-unescaped-regexp-dot.js @@ -1,6 +1,8 @@ 'use strict'; -require('../common'); +const common = require('../common'); + +common.skipIfEslintMissing(); const RuleTester = require('../../tools/node_modules/eslint').RuleTester; const rule = require('../../tools/eslint-rules/no-unescaped-regexp-dot'); |