Reinstate error code in resolve promise for api tests.

This commit is contained in:
Blade Barringer
2015-10-26 07:53:51 -05:00
parent 01914523e1
commit 04fbdaa107
8 changed files with 56 additions and 14 deletions

View File

@@ -15,7 +15,10 @@ describe('DELETE /user', () => {
it('deletes the user', () => {
return expect(api.del('/user').then((fetchedUser) => {
return api.get('/user');
})).to.be.rejectedWith('No user found.');
})).to.eventually.be.rejected.and.eql({
code: 401,
text: 'No user found.',
});
});
context('user in solo group', () => {