Fix article test to handle patches endpoint change

This commit is contained in:
Scott Erickson 2016-08-23 16:19:10 -07:00
parent c3b3c6ea2a
commit b175c02714

View file

@ -613,9 +613,9 @@ describe 'GET /db/article/:handle/patches', ->
expect(patches[0]._id).toBe(patch._id) expect(patches[0]._id).toBe(patch._id)
done() done()
it 'returns 422 for invalid object ids', utils.wrap (done) -> it 'returns 404 for handles that do not exist', utils.wrap (done) ->
[res, body] = yield request.getAsync getURL("/db/article/invalid/patches"), { json: true } [res, body] = yield request.getAsync getURL("/db/article/dne/patches"), { json: true }
expect(res.statusCode).toBe(422) expect(res.statusCode).toBe(404)
done() done()