Support multiple Zed selections in TUI context (#25140)

This commit is contained in:
Kit Langton
2026-04-30 14:15:50 -04:00
committed by GitHub
parent 19271fca2d
commit 320527a3e4
5 changed files with 278 additions and 89 deletions

View File

@@ -190,13 +190,17 @@ test("useEditorContext resets selection when reconnecting", async () => {
serverInfo: { name: "test", version: "0.0.0" },
})
expect(mounted.editor.selection()).toEqual({
text: "foo",
filePath: path.join(startupDirectory, "file.ts"),
source: "websocket",
selection: {
start: { line: 1, character: 1 },
end: { line: 1, character: 4 },
},
ranges: [
{
text: "foo",
selection: {
start: { line: 1, character: 1 },
end: { line: 1, character: 4 },
},
},
],
})
mounted.editor.reconnect(startupDirectory)