Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

expect-matcher doesn't work correctly inside arrow function expression #174

Open
asapach opened this issue Jan 7, 2019 · 0 comments · May be fixed by #175
Open

expect-matcher doesn't work correctly inside arrow function expression #174

asapach opened this issue Jan 7, 2019 · 0 comments · May be fixed by #175

Comments

@asapach
Copy link

asapach commented Jan 7, 2019

Do you want to request a feature or report a bug?
Bug

What is the current behavior?
expect-matcher rule doesn't detect the missing matcher inside arrow function expression:

it("test", () => expect("something"))

If the current behavior is a bug, please provide the steps to reproduce.

parserOptions:
  ecmaVersion: 6
plugins:
  - jasmine
env:
  jasmine: true
rules:
  jasmine/expect-matcher: 2

What is the expected behavior?
The expected error message is:

Expect must have a corresponding matcher call. (jasmine/expect-matcher)

It does work correctly for statement block though:

it("test", () => {
  expect("something"))
}

And when the matcher is not being called:

it("test", () => expect("something").toBe)

Please mention your node.js, eslint-plugin-jasmine and operating system version.
Windows 10 x64
Node v8.14.0
[email protected]
[email protected]

asapach added a commit to asapach/eslint-plugin-jasmine that referenced this issue Jan 7, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant