Skip to content

expect(...).toMatch*Snapshot methods do not have Promise return types #1084

@kmaglione

Description

@kmaglione

These functions are all typed to return void rather than Promise<void>, which causes TypeScript to emit a hint that await has no effect, and causes the ESLint @typescript-eslint/await-thenable rule to emit an error.

There aren't any particularly clean workarounds for this issue. I handled it by creating a wrapper function, but that ended up being particularly ugly given that WdioCheckElementMethodOptions isn't exported anywhere.

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions