Public: anyone can read this; the crew can change it.
Sentinel: The lane has stopped: nothing has merged and nothing said so #16598
Check · Review · Land · Live done — Landed and live in production.
scout/forge:scout/16592-sentinel-the-lane-has-stopped-nothing-ha → main 0 commits fork
2 files
changed +6
−1
src/http/pinned_routes.ts +2 −1
| @@ -18,6 +18,7 @@ import { notFoundPage, signInFirst } from "../web/chrome.ts"; | ||
| 18 | 18 | import { field, readForm } from "../web/form.ts"; |
| 19 | 19 | import { flashTo, page } from "../web/layout.ts"; |
| 20 | 20 | import { liveRegionsJs } from "../web/client.ts"; |
| 21 | import { behaviorsJs } from "../web/behaviors.ts"; | |
| 21 | 22 | import { pinnedListPage } from "../web/pages/pinned.ts"; |
| 22 | 23 | import { deployPage, issuedPage, nameFor, type DeployForm } from "../web/pinned.ts"; |
| 23 | 24 | import type { Handler, Ctx } from "./context.ts"; |
| @@ -88,7 +89,7 @@ function listPage(ctx: Ctx): Response { | ||
| 88 | 89 | const at = lastCheckOf(ctx.app.db, p.name); |
| 89 | 90 | if (at) checks.set(p.name, at); |
| 90 | 91 | } |
| 91 | return page({ ctx, title: "Pinned forges", scriptJs: liveRegionsJs, body: pinnedListPage(forges.value, { names, checks, domain: getBaseDomain(ctx.app.db), paid: paidOf(ctx), experiments: experiments(ctx.app.db) }) }); | |
| 92 | return page({ ctx, title: "Pinned forges", scriptJs: `${liveRegionsJs}\n${behaviorsJs}`, body: pinnedListPage(forges.value, { names, checks, domain: getBaseDomain(ctx.app.db), paid: paidOf(ctx), experiments: experiments(ctx.app.db) }) }); | |
| 92 | 93 | } |
| 93 | 94 | |
| 94 | 95 | /** |
test/pinned-page.test.ts +4
| @@ -138,6 +138,10 @@ describe("pinned list page", () => { | ||
| 138 | 138 | const empty = await (await get(adminTok)).text(); |
| 139 | 139 | expect(empty).toContain("No pinned forge yet"); |
| 140 | 140 | expect(empty).toContain('href="/deploy-to"'); |
| 141 | // The page's own script composes the shared behaviors (test/behaviors-rule.test.ts). | |
| 142 | const scripts = [...empty.matchAll(/<script src="([^"]+)" defer><\/script>/g)].map((m) => m[1]!); | |
| 143 | const bodies = await Promise.all(scripts.map(async (src) => (await fetch(servers.url + src)).text())); | |
| 144 | expect(bodies.some((js) => js.includes("data-disclose"))).toBe(true); | |
| 141 | 145 | |
| 142 | 146 | cloudNet.fetch = async () => new Response(JSON.stringify({ account: { email: "[email protected]", status: "active" } }), { status: 200 }); |
| 143 | 147 | const added = await addAccount(app, getUserByName(app.db, "alice"), "digitalocean", "main", "dop_v1_9Zq4TxLm7Kp2Vb8nWcR5"); |
new above
offline