test: add missing "return" in a promise-style test
Before this change, when the test failed, the rejected promise was not reported back to mocha and triggered "unhandled promise rejection" warning only.
This commit is contained in:
parent
d23ff84587
commit
3723f107db
|
@ -1407,7 +1407,7 @@ describe('User', function() {
|
||||||
});
|
});
|
||||||
|
|
||||||
it('changes the password - instance method', () => {
|
it('changes the password - instance method', () => {
|
||||||
validCredentialsUser.changePassword(currentPassword, 'new password')
|
return validCredentialsUser.changePassword(currentPassword, 'new password')
|
||||||
.then(() => {
|
.then(() => {
|
||||||
expect(arguments.length, 'changePassword promise resolution')
|
expect(arguments.length, 'changePassword promise resolution')
|
||||||
.to.equal(0);
|
.to.equal(0);
|
||||||
|
|
Loading…
Reference in New Issue