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

Update properties in sendMock #7

Open
openam opened this issue May 25, 2016 · 0 comments
Open

Update properties in sendMock #7

openam opened this issue May 25, 2016 · 0 comments

Comments

@openam
Copy link

openam commented May 25, 2016

We should update the properties in the error to be something like errorData and errorCode.
https://github.com/sinet/lapin-mock/blob/master/lib/sendMock.js#L14-L15

I've seen tests that are too loosely written with like this:

it( 'should return `error` status', function () {
    sendMock.should.have.property( 'error' );
} );

By default sendMock will always have an error property. If the tests were written tighter and checked to make sure it was no longer a function it would be fine, or better yet it should assert the actual error message.

@openam openam assigned openam and yamii and unassigned openam May 25, 2016
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

No branches or pull requests

2 participants