fix: align release checks with current note and diagram behavior

This commit is contained in:
tianma-if committed 2026-10-08 22:51:06 +08:00
1 parent 0588a552c8
commit e93c2882b0
3 files changed
+7 -13

No files matched your search

@@ -315,11 +315,7 @@ describe("managed ACP adapters", () => {
arch: "arm64",
fetchImpl: async (url) => {
if (url.endsWith(".zip")) {
return new Response(new ReadableStream({
start(controller) {
controller.error(new Error("aborted_after_header_check"));
},
}), {
return new Response(new Uint8Array([0]), {
status: 200,
headers: { "content-length": String(contentLength) },
});
@@ -328,7 +324,7 @@ describe("managed ACP adapters", () => {
},
});
try {
await expect(manager.install("antigravity", async () => ({ state: "available" }))).rejects.toThrow("aborted_after_header_check");
await expect(manager.install("antigravity", async () => ({ state: "available" }))).rejects.toThrow("invalid_adapter_archive");
contentLength = 501 * 1024 * 1024;
await expect(manager.install("antigravity", async () => ({ state: "available" }))).rejects.toThrow("adapter_too_large");
} finally {
@@ -337,5 +333,3 @@ describe("managed ACP adapters", () => {
});
});
+1 -1
View File
@@ -1,4 +1,4 @@
// The note editor surface, `--workspace-editor` in apps/web/src/styles/globals.css.
// Every diagram canvas uses it, so a color theme does not tint the page.
export const DIAGRAM_CANVAS_LIGHT = "#f8fafb";
export const DIAGRAM_CANVAS_DARK = "#191e1b";
export const DIAGRAM_CANVAS_DARK = "#222325";
+4 -4
View File
@@ -90,9 +90,9 @@ describe("mobile app scope", () => {
});
test("keeps version history reachable from an active note", () => {
expect(memoDetailSource).toMatch(
/\{memo && !memo\.isDeleted \? \(\s*<Pressable\s+accessibilityLabel="版本历史"/
);
expect(memoDetailSource).toContain("{!memo.isDeleted ? (");
expect(memoDetailSource).toContain('label={resolvedLocale !== "zh-CN" ? "Version history" : "版本历史"}');
expect(memoDetailSource).toContain("onPress={() => closeActionsAndRun(() => onOpenRevisions(memo))}");
expect(memoDetailSource).toContain('syncStatus === "conflict"');
expect(memoDetailSource).toContain("onResolveSyncConflict");
});
@@ -214,7 +214,7 @@ describe("mobile app scope", () => {
expect(localTiptapEditorSource).toContain("autofocus: false");
expect(localTiptapEditorSource).toContain('import("mermaid/dist/mermaid.min.js")');
expect(localTiptapEditorSource).toContain('import("beautiful-mermaid")');
expect(localTiptapEditorSource).toContain('import("html-to-image")');
expect(localTiptapEditorSource).toContain('import { toCanvas } from "html-to-image"');
expect(localTiptapEditorSource).not.toContain('import "mermaid/dist/mermaid.min.js"');
});