test(team-mode): stabilize resume stale reservation history check
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent) Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
This commit is contained in:
@@ -380,8 +380,8 @@ describe("resumeAllTeams", () => {
|
|||||||
}))
|
}))
|
||||||
const ancientMtime = new Date(Date.now() - 60 * 60 * 1000)
|
const ancientMtime = new Date(Date.now() - 60 * 60 * 1000)
|
||||||
await utimes(reservedPath, ancientMtime, ancientMtime)
|
await utimes(reservedPath, ancientMtime, ancientMtime)
|
||||||
const sessionGet = mock(async () => ({ data: { id: "alive" } }))
|
const sessionGet: SessionGetMock = async () => ({ data: { id: "alive" } })
|
||||||
const sessionMessages = mock(async ({ path: sessionPath }: { path: { id: string } }) => ({
|
const sessionMessages: SessionMessagesMock = async ({ path: sessionPath }) => ({
|
||||||
data: sessionPath.id === "ses_worker"
|
data: sessionPath.id === "ses_worker"
|
||||||
? [
|
? [
|
||||||
{
|
{
|
||||||
@@ -395,7 +395,7 @@ describe("resumeAllTeams", () => {
|
|||||||
},
|
},
|
||||||
]
|
]
|
||||||
: [],
|
: [],
|
||||||
}))
|
})
|
||||||
|
|
||||||
// when
|
// when
|
||||||
await resumeAllTeams(createExecutorContext(baseDir, sessionGet, sessionMessages), config)
|
await resumeAllTeams(createExecutorContext(baseDir, sessionGet, sessionMessages), config)
|
||||||
|
|||||||
Reference in New Issue
Block a user