refactoring

This commit is contained in:
2026-09-02 08:38:03 +02:00
parent 649ff0d7c5
commit 38f255c1a4
48 changed files with 6998 additions and 5577 deletions
+4 -4
View File
@@ -16,7 +16,7 @@ function fakeNode(attributes) {
};
}
function loadEditorFactory() {
async function loadEditorFactory() {
global.Element = class Element {};
global.document = {
currentScript: null,
@@ -30,12 +30,12 @@ function loadEditorFactory() {
clearTimeout,
requestAnimationFrame: (callback) => callback()
};
require("../static/cmap/cmap-racket-wiki.js");
await import("../static/cmap/cmap-racket-wiki.js");
return global.window.RacketWikiCmap;
}
test("back from a second nested submap returns exactly one map level", () => {
const factory = loadEditorFactory();
test("back from a second nested submap returns exactly one map level", async () => {
const factory = await loadEditorFactory();
const map = {
onSelection() {},
onActivation() {},