7773-testToMaster_2430 #2774

Merged
alexm merged 368 commits from 7773-testToMaster_2430 into master 2024-07-23 06:21:03 +00:00
1 changed files with 2 additions and 8 deletions
Showing only changes of commit b4afb883fc - Show all commits

View File

@ -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() {