diff --git a/karma.conf.js b/karma.conf.js index 025f1170..685e2d4a 100644 --- a/karma.conf.js +++ b/karma.conf.js @@ -28,14 +28,15 @@ module.exports = function(config) { files: [ - // System.js for module loading - 'node_modules/systemjs/dist/system-polyfills.js', - 'node_modules/systemjs/dist/system.src.js', // Polyfills 'node_modules/core-js/client/shim.js', 'node_modules/reflect-metadata/Reflect.js', + // System.js for module loading + 'node_modules/systemjs/dist/system.js', + + // zone.js 'node_modules/zone.js/dist/zone.js', 'node_modules/zone.js/dist/long-stack-trace-zone.js', diff --git a/test/backend/unit/middlewares/uesr/AuthenticationMWs.ts b/test/backend/unit/middlewares/uesr/AuthenticationMWs.ts index cc505eac..ab510f08 100644 --- a/test/backend/unit/middlewares/uesr/AuthenticationMWs.ts +++ b/test/backend/unit/middlewares/uesr/AuthenticationMWs.ts @@ -4,6 +4,7 @@ import {Error, ErrorCodes} from "../../../../../common/entities/Error"; import {UserRoles} from "../../../../../common/entities/UserDTO"; import {ObjectManagerRepository} from "../../../../../backend/model/ObjectManagerRepository"; import {UserManager} from "../../../../../backend/model/memory/UserManager"; +import {Config} from "../../../../../backend/config/Config"; describe('Authentication middleware', () => { @@ -31,6 +32,7 @@ describe('Authentication middleware', () => { let req:any = { session: {} }; + Config.Client.authenticationRequired = true; let res:any = {}; let next:any = (err:Error) => { expect(err).not.to.be.undefined;