Convert remaining active api tests to use promises

This commit is contained in:
Blade Barringer
2015-10-25 11:09:50 -05:00
parent 12ce4b133d
commit f06d3cdffe
4 changed files with 9 additions and 13 deletions

View File

@@ -12,14 +12,13 @@ describe('GET /user', () => {
});
});
it('gets the user object', (done) => {
it('gets the user object', () => {
let api = requester(user);
api.get('/user').then((fetchedUser) => {
return api.get('/user').then((fetchedUser) => {
expect(fetchedUser._id).to.eql(user._id);
expect(fetchedUser.auth.local.username).to.eql(user.auth.local.username);
expect(fetchedUser.todos).to.eql(user.todos);
expect(fetchedUser.items).to.eql(user.items);
done();
});
});
});