feat: mem slash commands (#11569)

Add 2 slash commands for memories:
* `/m_drop` delete all the memories
* `/m_update` update the memories with phase 1 and 2
This commit is contained in:
jif-oai
2026-02-12 10:39:43 +00:00
committed by GitHub
parent 4027f1f1a4
commit a0dab25c68
6 changed files with 134 additions and 1 deletions

View File

@@ -3380,6 +3380,24 @@ async fn slash_clean_submits_background_terminal_cleanup() {
);
}
#[tokio::test]
async fn slash_memory_drop_submits_drop_memories_op() {
let (mut chat, _rx, mut op_rx) = make_chatwidget_manual(None).await;
chat.dispatch_command(SlashCommand::MemoryDrop);
assert_matches!(op_rx.try_recv(), Ok(Op::DropMemories));
}
#[tokio::test]
async fn slash_memory_update_submits_update_memories_op() {
let (mut chat, _rx, mut op_rx) = make_chatwidget_manual(None).await;
chat.dispatch_command(SlashCommand::MemoryUpdate);
assert_matches!(op_rx.try_recv(), Ok(Op::UpdateMemories));
}
#[tokio::test]
async fn slash_resume_opens_picker() {
let (mut chat, mut rx, _op_rx) = make_chatwidget_manual(None).await;