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

I get errors on the "async" rule when the function isn't async due to it being "pending" #17

Open
dietergeerts opened this issue Oct 27, 2021 · 0 comments · May be fixed by #23
Open

I get errors on the "async" rule when the function isn't async due to it being "pending" #17

dietergeerts opened this issue Oct 27, 2021 · 0 comments · May be fixed by #23

Comments

@dietergeerts
Copy link

dietergeerts commented Oct 27, 2021

Given the following code:

Then(
  /^I see an inline error stating the patients failed to fetch$/,
  () => 'pending',
);

I get an error thrown:

TypeError: Cannot read property 'length' of undefined
at didNotReturnAnythingIn (.....node_modules\.pnpm\[email protected]\node_modules\eslint-plugin-cucumber\lib\rules\async-then.
js:49:17)

Adding "async/await" here gives other linting errors, because it's not needed in this case.
The step is pending because we will not implement it yet... This is normal in writing E2E tests in a larger team.
So unless there is another way to state a step as pending that doesn't let this check fail, this has to be fixed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant