mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-26 14:55:13 +00:00
test: tighten session store rpc assertions
This commit is contained in:
@@ -75,17 +75,14 @@ test("lists and patches session store via sessions.* RPC", async () => {
|
||||
});
|
||||
|
||||
const { ws, hello } = await openClient();
|
||||
expect((hello as { features?: { methods?: string[] } }).features?.methods).toEqual(
|
||||
expect.arrayContaining([
|
||||
"sessions.list",
|
||||
"sessions.preview",
|
||||
"sessions.cleanup",
|
||||
"sessions.patch",
|
||||
"sessions.reset",
|
||||
"sessions.delete",
|
||||
"sessions.compact",
|
||||
]),
|
||||
);
|
||||
const methods = (hello as { features?: { methods?: string[] } }).features?.methods ?? [];
|
||||
expect(methods).toContain("sessions.list");
|
||||
expect(methods).toContain("sessions.preview");
|
||||
expect(methods).toContain("sessions.cleanup");
|
||||
expect(methods).toContain("sessions.patch");
|
||||
expect(methods).toContain("sessions.reset");
|
||||
expect(methods).toContain("sessions.delete");
|
||||
expect(methods).toContain("sessions.compact");
|
||||
const sessionsHandlers = await getSessionsHandlers();
|
||||
const { getRuntimeConfig } = await getGatewayConfigModule();
|
||||
const directContext = {
|
||||
|
||||
Reference in New Issue
Block a user