mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-17 22:57:21 +01:00
Change helper to reject only error message
This commit is contained in:
@@ -16,13 +16,13 @@ describe('DELETE /user', () => {
|
||||
it('deletes the user', (done) => {
|
||||
api.del('/user')
|
||||
.then((fetchedUser) => {
|
||||
return api.get('/user')
|
||||
return api.get('/user');
|
||||
})
|
||||
.then((deletedUser) => {
|
||||
done('Unexpected user');
|
||||
})
|
||||
.catch((err) => {
|
||||
expect(err.code).to.eql(401);
|
||||
expect(err).to.eql('No user found.');
|
||||
done();
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user