mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-18 15:17:25 +01:00
15 lines
458 B
JavaScript
15 lines
458 B
JavaScript
import { requester } from '../../../../helpers/api-integration.helper';
|
|
|
|
describe('notFound Middleware', () => {
|
|
it('returns a 404 error when the resource is not found', () => {
|
|
let request = requester().get('/api/v3/dummy-url');
|
|
|
|
return request.then((errBody) => {
|
|
expect(errBody.error).to.equal('NotFound');
|
|
expect(errBody.message).to.equal('Not found.');
|
|
}).to.eventually.be.rejected.and.eql({
|
|
code: 404,
|
|
});
|
|
});
|
|
});
|