mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-01-20 22:42:53 -05:00
Migrated test to more readable syntax
no issue - A bit of a cleanup before touching this test suite. The use of `done` in tests is soooo outdated
This commit is contained in:
parent
63f2cfdd32
commit
2956c1e88a
1 changed files with 4 additions and 10 deletions
|
@ -113,17 +113,11 @@ describe('User API', function () {
|
||||||
});
|
});
|
||||||
|
|
||||||
describe('Destroy', function () {
|
describe('Destroy', function () {
|
||||||
it('[failure] Destroy unknown user id', function (done) {
|
it('[failure] Destroy unknown user id', function () {
|
||||||
request.delete(localUtils.API.getApiQuery('users/' + ObjectId().toHexString()))
|
return request
|
||||||
|
.delete(localUtils.API.getApiQuery('users/' + ObjectId().toHexString()))
|
||||||
.set('Origin', config.get('url'))
|
.set('Origin', config.get('url'))
|
||||||
.expect(404)
|
.expect(404);
|
||||||
.end(function (err) {
|
|
||||||
if (err) {
|
|
||||||
return done(err);
|
|
||||||
}
|
|
||||||
|
|
||||||
done();
|
|
||||||
});
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
Loading…
Add table
Reference in a new issue