mirror of
https://github.com/snapotter-hq/SnapOtter.git
synced 2026-08-03 07:46:42 +02:00
fix: harden Docker image and async job responses
Harden Docker runtime packaging, preserve async job response semantics, fix Redis subscriber startup connections, clear lint warnings, and harden enterprise S3 object body handling.
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
import { buildAsyncAcceptedPayload } from "../../../apps/api/src/routes/async-response.js";
|
||||
|
||||
describe("buildAsyncAcceptedPayload", () => {
|
||||
it("keeps legacy async shape when the progress and artifact IDs match", () => {
|
||||
expect(buildAsyncAcceptedPayload("job-123")).toEqual({
|
||||
jobId: "job-123",
|
||||
async: true,
|
||||
});
|
||||
});
|
||||
|
||||
it("exposes both progress and artifact IDs when a client progress ID is supplied", () => {
|
||||
expect(buildAsyncAcceptedPayload("artifact-123", "progress-456")).toEqual({
|
||||
jobId: "progress-456",
|
||||
progressJobId: "progress-456",
|
||||
artifactJobId: "artifact-123",
|
||||
async: true,
|
||||
});
|
||||
});
|
||||
});
|
||||
Reference in New Issue
Block a user