diff --git a/services/web/app/src/infrastructure/Server.js b/services/web/app/src/infrastructure/Server.js index cafa05a7e7..b9798e73f6 100644 --- a/services/web/app/src/infrastructure/Server.js +++ b/services/web/app/src/infrastructure/Server.js @@ -234,6 +234,10 @@ if (enableWebRouter || notDefined(enableWebRouter)) { logger.info('precompiling views for web in production environment') Views.precompileViews(app) } + if (app.get('env') === 'test') { + logger.info('enabling view cache for acceptance tests') + app.enable('view cache') + } app.use(publicApiRouter) // public API goes with web router for public access app.use(Validation.errorMiddleware)