Skip to content

Commit

Permalink
test(eslint-plugin): arrow-paren: add extra case (#432)
Browse files Browse the repository at this point in the history
  • Loading branch information
bradzacher authored and JamesHenry committed Apr 24, 2019
1 parent 3f305b1 commit 06538e3
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .vscode/launch.json
Expand Up @@ -12,7 +12,8 @@
"program": "${workspaceFolder}/node_modules/jest/bin/jest.js",
"args": [
"--runInBand",
"tests/rules/${fileBasenameNoExtension}"
// needs the '' around it so that the () are properly handled
"'tests/(.+/)?${fileBasenameNoExtension}'"
],
"sourceMaps": true,
"console": "integratedTerminal",
Expand Down
Expand Up @@ -13,6 +13,11 @@ ruleTester.run('arrow-parens', rule, {
'const foo = <T>(t: T) => {};',
'const foo = <T>((t: T) => {});',
'const foo = function <T>(t: T) {};',
`
const foo = <T>(bar: any): void => {
// Do nothing
}
`,
{
code: 'const foo = t => {};',
options: ['as-needed'],
Expand Down

0 comments on commit 06538e3

Please sign in to comment.