overleaf/services/web/test/acceptance/src/mocks/MockNotificationsApi.js
Jakob Ackermann a2000cb171 Merge pull request #3703 from overleaf/jpa-spd-mocks-reset-is-optional
[tests] mocks: .reset() is optional

GitOrigin-RevId: ad2db1ecc69f57fa9deea0ff124e3f0be212f0ee
2021-02-26 03:04:37 +00:00

22 lines
655 B
JavaScript

const AbstractMockApi = require('./AbstractMockApi')
// Currently there is nothing implemented here as we have no acceptance tests
// for the notifications API. This does however stop errors appearing in the
// output when the acceptance tests try to connect.
class MockNotificationsApi extends AbstractMockApi {
applyRoutes() {
this.app.get('/*', (req, res) => res.sendStatus(200))
this.app.post('/*', (req, res) => res.sendStatus(200))
}
}
module.exports = MockNotificationsApi
// type hint for the inherited `instance` method
/**
* @function instance
* @memberOf MockNotificationsApi
* @static
* @returns {MockNotificationsApi}
*/