arguments to `webdrivercss` callback aren't documented #41

Closed
cvrebert opened this Issue Dec 7, 2014 · 3 comments

Projects

None yet

4 participants

@cvrebert
Contributor
cvrebert commented Dec 7, 2014

https://github.com/webdriverio/webdrivercss#usage says you can pass in a callback argument, but doesn't state what arguments that callback will be invoked with.

The res argument appears to be an object mapping names from the webdrivercss call to some array of objects of some type (which also isn't documented!) that has useful properties such as isWithinMisMatchTolerance.

@amitaibu
Member

I believe the arguments are err, and res. from the exmaple

// ...
], function(err, res) {
        assert.ifError(err);
        assert.ok(res.header[0].isWithinMisMatchTolerance);
        assert.ok(res.hero[0].isWithinMisMatchTolerance);
    })
@christian-bromann
Member

@cvrebert is right. There is currently a lack of documentation here. Hope we can fix that soon. Looking for any kind of contribution.

@jamesdwilson
Contributor

+1

@christian-bromann christian-bromann pushed a commit that closed this issue Apr 19, 2016
@klamping klamping Fix #41: Details on res object returned to webdrivercss callback
Also fixed missing `header[0]` code in assertion.
6e86b55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment