feat: gate every surface on CoeditingRegistry (INV-10) — commenting ranges re-assigned on gate change (spec §6.4 v0.2.1)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -20,6 +20,12 @@ async function freshDoc(rel: string, body: string): Promise<{ doc: vscode.TextDo
|
||||
fs.writeFileSync(abs, body, "utf8");
|
||||
const uri = vscode.Uri.file(abs);
|
||||
const doc = await vscode.workspace.openTextDocument(uri);
|
||||
// INV-10: cowriting.editDocument now warns instead of editing a non-entered
|
||||
// doc (Task 4) — enter it here (briefly making it active) so the tests below
|
||||
// exercise the routing/targeting behavior, not the gate. The caller
|
||||
// re-establishes whichever doc it wants active afterward.
|
||||
await vscode.window.showTextDocument(doc);
|
||||
await vscode.commands.executeCommand("cowriting.coeditDocument");
|
||||
return { doc, key: uri.toString() };
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user