feat(image): complete reviewed generation delivery
Memind CI / Test, build, and release guards (pull_request) Successful in 2m47s
Memind CI / Test, build, and release guards (pull_request) Successful in 2m47s
This commit is contained in:
@@ -286,6 +286,17 @@ function createFakePool({ sessionDeliverables = {}, workspaceDeliverables = {} }
|
||||
const id = params.at(-1);
|
||||
const row = runs.get(id);
|
||||
if (!row) return [{ affectedRows: 0 }];
|
||||
if (sql.includes("status = 'running'") && sql.includes('started_at = COALESCE(started_at, ?)')) {
|
||||
const [attempts, startedAt, updatedAt] = params;
|
||||
Object.assign(row, {
|
||||
status: 'running',
|
||||
attempts,
|
||||
started_at: row.started_at ?? startedAt,
|
||||
updated_at: updatedAt,
|
||||
error_message: null,
|
||||
});
|
||||
return [{ affectedRows: 1 }];
|
||||
}
|
||||
const columns = [...sql.matchAll(/([a-z_]+) = \?/g)].map((match) => match[1]);
|
||||
for (let i = 0; i < columns.length; i += 1) {
|
||||
row[columns[i]] = params[i];
|
||||
@@ -645,7 +656,8 @@ test('agent run succeeds when Finish is missing but session pages were already c
|
||||
);
|
||||
});
|
||||
|
||||
test('static page run succeeds when no Page Data artifact path is recorded', async () => {
|
||||
test('static page run succeeds when workspace fallback reports the current HTML path', async () => {
|
||||
let observedRunStartedAtMs = null;
|
||||
const pool = createFakePool({
|
||||
workspaceDeliverables: {
|
||||
'user-1': [{
|
||||
@@ -670,8 +682,15 @@ test('static page run succeeds when no Page Data artifact path is recorded', asy
|
||||
return { ok: true, finishEvent: { type: 'Finish' } };
|
||||
},
|
||||
},
|
||||
// This mirrors a static-page-publish run: no Page Data artifact list.
|
||||
syncUserPagesOnSuccess: async () => ({ pageDataBind: { errors: [] }, pageDataRelativePaths: [] }),
|
||||
// Static-page-publish may have no conversation artifact, but the server
|
||||
// reports the current run's recently modified workspace HTML explicitly.
|
||||
syncUserPagesOnSuccess: async ({ runStartedAtMs }) => {
|
||||
observedRunStartedAtMs = runStartedAtMs;
|
||||
return {
|
||||
pageDataBind: { errors: [] },
|
||||
pageDataRelativePaths: ['public/urban-fashion.html'],
|
||||
};
|
||||
},
|
||||
retryDelaysMs: [],
|
||||
});
|
||||
|
||||
@@ -684,6 +703,7 @@ test('static page run succeeds when no Page Data artifact path is recorded', asy
|
||||
});
|
||||
|
||||
await waitFor(() => pool.runs.get(run.id)?.status === 'succeeded');
|
||||
assert.ok(Number(observedRunStartedAtMs) > 0);
|
||||
});
|
||||
|
||||
test('agent run uses direct chat service for eligible chat messages', async () => {
|
||||
|
||||
Reference in New Issue
Block a user