@samitouri / QOS-React-2 / commits / 7439b48cf4

Add explicit support for ESLint 6.0.0 (#15974)

Preemptively update tests wrt 'parser' requiring an absolute path rather than a package name, even though the project is still using ESLint 4. Fixes #15971

Thomas Broyer committed Jun 24, 2019 at 23:30 UTC 7439b48cf4356473e4f1596e47aac34c8345163a
3 files changed +3 -3
packages/eslint-plugin-react-hooks/__tests__/ESLintRuleExhaustiveDeps-test.js
+1 -1
@@ -12,7 +12,7 @@ const ReactHooksESLintPlugin = require('eslint-plugin-react-hooks');
12 const ReactHooksESLintRule = ReactHooksESLintPlugin.rules['exhaustive-deps'];
13
14 ESLintTester.setDefaultConfig({
15 - parser: 'babel-eslint',
15 + parser: require.resolve('babel-eslint'),
16 parserOptions: {
17 ecmaVersion: 6,
18 sourceType: 'module',
packages/eslint-plugin-react-hooks/__tests__/ESLintRulesOfHooks-test.js
+1 -1
@@ -12,7 +12,7 @@ const ReactHooksESLintPlugin = require('eslint-plugin-react-hooks');
12 const ReactHooksESLintRule = ReactHooksESLintPlugin.rules['rules-of-hooks'];
13
14 ESLintTester.setDefaultConfig({
15 - parser: 'babel-eslint',
15 + parser: require.resolve('babel-eslint'),
16 parserOptions: {
17 ecmaVersion: 6,
18 sourceType: 'module',
packages/eslint-plugin-react-hooks/package.json
+1 -1
@@ -29,6 +29,6 @@
29 },
30 "homepage": "https://reactjs.org/",
31 "peerDependencies": {
32 - "eslint": "^3.0.0 || ^4.0.0 || ^5.0.0"
32 + "eslint": "^3.0.0 || ^4.0.0 || ^5.0.0 || ^6.0.0"
33 }
34 }