Keep UAT CCS smoke on management cases

This commit is contained in:
hz
2026-08-06 02:57:08 -05:00
parent a0dae8e478
commit 0c330380da
+5 -1
View File
@@ -183,8 +183,10 @@ test("public API and disposable learner journey", async () => {
const { data: cases } = await call("/api/ccs/cases", { token });
expect(Array.isArray(cases)).toBeTruthy();
expect(cases.length).toBeGreaterThan(0);
const managementCase = cases.find((item) => item.experienceMode === "management");
expect(managementCase, "UAT requires a published management CCS case for the smoke journey").toBeTruthy();
const { data: attempt } = await call("/api/ccs/attempts", {
method: "POST", token, body: { caseExternalId: "", mode: "timed" }
method: "POST", token, body: { caseExternalId: managementCase.externalId, mode: "timed" }
});
activeCcsAttempt = attempt.id;
expect(activeCcsAttempt).toBeTruthy();
@@ -204,6 +206,8 @@ test("public API and disposable learner journey", async () => {
}
});
expect(opened.openingCompleted).toBe(true);
expect(Array.isArray(opened.availableExams)).toBeTruthy();
expect(opened.availableExams.length, "management CCS smoke case must expose at least one exam").toBeGreaterThan(0);
const exam = opened.availableExams[0];
const { data: examined } = await call(`/api/ccs/attempts/${activeCcsAttempt}/commands/batch`, {
method: "POST", token, body: {