Open VinhVu0412 opened 5 years ago
Mocha always expects the done
callback parameter to be the first argument. The behavior of injecting the browser
parameter is added by nightwatch and is not compatible with the default behavior of mocha.
That’s being said, I would be open for a change proposal that solves this kind of issues in a generic way (i.e. not nightwatch specific). Maybe something like adding a configuration option that allows you to specify the expected argument position.
That sounds great. At this point of time, I'll stay with inline ignore.
I am using nightwatch with mocha, my test function look like this
(More detail about using mocha with nightwatch is here)
When I check with eslint, it says
error Expected "browser" callback to be handled mocha/handle-done-callback
I am using
The checker thinks
browser
isdone
callback, but it's not.