PR comments.

This commit is contained in:
mike12345567 2025-03-03 14:20:44 +00:00
parent 3d7270983c
commit 0669151704
1 changed files with 9 additions and 5 deletions

View File

@ -1,8 +1,6 @@
import { DEFAULT_TABLES } from "../../../db/defaultData/datasource_bb_default"
import { setEnv } from "../../../environment"
setEnv({ USE_LOCAL_COMPONENT_LIBS: "0" })
jest.mock("../../../utilities/redis", () => ({
init: jest.fn(),
getLocksById: () => {
@ -30,10 +28,16 @@ import path from "path"
describe("/applications", () => {
let config = setup.getConfig()
let app: App
let app: App, cleanup: () => void
afterAll(setup.afterAll)
beforeAll(async () => await config.init())
afterAll(() => {
setup.afterAll()
cleanup()
})
beforeAll(async () => {
cleanup = setEnv({ USE_LOCAL_COMPONENT_LIBS: "0" })
await config.init()
})
beforeEach(async () => {
app = await config.api.application.create({ name: utils.newid() })