From b4afb883fc71e335ef41572d2dbc77c1126f0536 Mon Sep 17 00:00:00 2001 From: Javier Segarra Date: Wed, 26 Jun 2024 09:35:18 +0200 Subject: [PATCH] feat(salix): refs #6436 #6436 remove unnecessary object.assign --- back/vn-jasmine.js | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/back/vn-jasmine.js b/back/vn-jasmine.js index c2d8a497c..2b981c6d9 100644 --- a/back/vn-jasmine.js +++ b/back/vn-jasmine.js @@ -27,13 +27,7 @@ const default_loopback_ctx = userId => { }; function vnBeforeAll() { - Object.assign(beforeAll, {getCtx: default_before_all}); - Object.assign(beforeAll, {mockLoopBackContext}); -} -function mockBeforeAll(value = default_before_all) { - const origin = beforeAll.ctx; - Object.assign(origin, value); - return origin; + Object.assign(beforeAll, {getCtx: default_before_all, mockLoopBackContext}); } const mockLoopBackContext = userId => { @@ -46,7 +40,7 @@ const mockLoopBackContext = userId => { return activeCtx; }; module.exports = { - mockBeforeAll, mockLoopBackContext + mockLoopBackContext }; (function init() {