mirror of
https://github.com/hansjone/dsh-im-ops.git
synced 2026-10-10 02:40:45 +08:00
feat: add session and preset list aliases
This commit is contained in:
parent
92ec91b7bd
commit
98c1e48271
21 changed files with 112 additions and 58 deletions
|
|
@ -3768,7 +3768,7 @@ test('preset card selection does not expose internal update errors', async () =>
|
|||
|
||||
function cards(messages) { return messages.filter((m) => m.msgType === 'interactive'); }
|
||||
|
||||
test('session list paginates by page number across 25 sessions', async () => {
|
||||
test('/sessions alias uses the interactive session list and paginates across 25 sessions', async () => {
|
||||
const fixture = stateFixture();
|
||||
const sent = [];
|
||||
const bridge = new FeishuHarnessBridge({
|
||||
|
|
@ -3782,7 +3782,7 @@ test('session list paginates by page number across 25 sessions', async () => {
|
|||
allowedSenderOpenIds: new Set(['ou_owner']),
|
||||
});
|
||||
|
||||
await bridge.accept(event('sessions-open', '/sessionlist', { senderOpenId: 'ou_owner' }));
|
||||
await bridge.accept(event('sessions-open', ' /SESSIONS ', { senderOpenId: 'ou_owner' }));
|
||||
await bridge.waitForIdle();
|
||||
assert.equal(cards(sent).length, 1);
|
||||
const page0 = cards(sent).at(-1).content;
|
||||
|
|
@ -3870,7 +3870,7 @@ test('session pagination preserves an explicitly selected workspace', async () =
|
|||
allowedSenderOpenIds: new Set(['ou_owner']),
|
||||
});
|
||||
|
||||
await bridge.accept(event('selected-workspace-open', '/sessionlist 2', { senderOpenId: 'ou_owner' }));
|
||||
await bridge.accept(event('selected-workspace-open', '/sessions 2', { senderOpenId: 'ou_owner' }));
|
||||
await bridge.waitForIdle();
|
||||
assert.equal(useActionsFromCard(cards(sent).at(-1).content)[0], 'selected-01');
|
||||
|
||||
|
|
|
|||
|
|
@ -67,6 +67,8 @@ test('menu exposes the increased command set and keeps permission completion num
|
|||
test('menu and card help advertise Agent Preset, reasoning, and batch commands', () => {
|
||||
const help = menuHelpText();
|
||||
assert.match(help, /\/presetlist/);
|
||||
assert.match(help, /\/presets/);
|
||||
assert.match(help, /\/sessions/);
|
||||
assert.match(help, /\/preset \[序号或完整ID\]/);
|
||||
assert.match(help, /\/preset id:<ID>/);
|
||||
assert.match(help, /\/preset --default/);
|
||||
|
|
@ -79,6 +81,8 @@ test('menu and card help advertise Agent Preset, reasoning, and batch commands',
|
|||
assert.match(help, /\/version/);
|
||||
|
||||
const card = helpCard();
|
||||
assert.match(card, /\/presets/);
|
||||
assert.match(card, /\/sessions/);
|
||||
assert.match(card, /\/reasoninglist/);
|
||||
assert.match(card, /\/reasonings/);
|
||||
assert.match(card, /\/reasoning \[序号、等级ID或 --default\]/);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue