fix: always compare draft identity, gate auto-send until checked
Co-Authored-By: Ovis Fast (Claude) <[email protected]>
This commit is contained in:
1 parent
e7deca480a
commit
57761326fd
7 files changed
+161
-34
No files matched your search
@@ -53,3 +53,11 @@ test("insertedNewline finds the index", () => {
|
||||
assert.deepEqual(insertedNewline("ab", "a\nb"), { index: 1 });
|
||||
assert.equal(insertedNewline("ab", "abc"), null);
|
||||
});
|
||||
|
||||
test("canAutoSend waits for the draft/identity check of the agent", async () => {
|
||||
const { canAutoSend } = await import("../mod/ovis-composer/view.js");
|
||||
assert.equal(canAutoSend(new Set(), "t2"), false);
|
||||
assert.equal(canAutoSend(new Set(["t2"]), "t2"), true);
|
||||
assert.equal(canAutoSend(new Set(["t3"]), "t2"), false);
|
||||
assert.equal(canAutoSend(null, "t2"), false);
|
||||
});
|
||||
Reference in new issue
Block a user