gui tests: old-webkit knows webfonts.js is imported, not a page script
a1f06bd78(Norcleeh's browser-tab fonts) added webfonts.js, which app.js's loadFonts imports in a browser tab only. old-webkit's "compat.js is the first of the page's own scripts" asks every asset .js to be in index.html, so it has been red on main since: "webfonts.js is not loaded by index.html". It now leaves webfonts.js out of that one check; the syntax and built-in checks still read it. Red on origin/maineb6d1d8d9(mote). At this head onaca0f0d8a, mote: node --test old-webkit (with nine other GUI files): 152 pass, 0 fail.
This commit is contained in:
@@ -141,7 +141,9 @@ test("compat.js is the first of the page's own scripts", async () => {
|
||||
const all = [...html.matchAll(/<script\s+src="([^"]+)"/g)].map((m) => m[1]);
|
||||
const srcs = all.filter((s) => s !== "boot.js" && s !== "theme.js" && s !== "omarchy.js");
|
||||
assert.equal(srcs[0], "compat.js", "loaded first: " + srcs.join(", "));
|
||||
for (const f of await scripts()) assert(all.includes(f), f + " is not loaded by index.html");
|
||||
// webfonts.js is imported by app.js in a browser tab only; the checks
|
||||
// above still read it
|
||||
for (const f of await scripts()) if (f !== "webfonts.js") assert(all.includes(f), f + " is not loaded by index.html");
|
||||
});
|
||||
|
||||
test("the styles hold up in Safari 15.0", async () => {
|
||||
|
||||
Reference in New Issue
Block a user