move tests into separate describe

This commit is contained in:
Peter Clement 2024-03-15 14:13:38 +00:00
parent 43308ad2f3
commit 61f0f5be18
1 changed files with 79 additions and 76 deletions

View File

@ -50,13 +50,6 @@ describe("REST Integration", () => {
const BASE_URL = "https://myapi.com"
let config: any
beforeAll(async () => {
await databaseTestProviders.s3.start()
})
afterAll(async () => {
await databaseTestProviders.s3.stop()
})
beforeEach(() => {
config = new TestConfiguration({
url: BASE_URL,
@ -632,6 +625,15 @@ describe("REST Integration", () => {
expect(calledConfig.agent.options.rejectUnauthorized).toBe(false)
})
describe("File Handling", () => {
beforeAll(async () => {
await databaseTestProviders.s3.start()
})
afterAll(async () => {
await databaseTestProviders.s3.stop()
})
it("uploads file to object store and returns signed URL", async () => {
const responseData = Buffer.from("teest file contnt")
const filename = "test.tar.gz"
@ -712,3 +714,4 @@ describe("REST Integration", () => {
})
})
})
})