Skip to content
Myr

env.test-d.ts

This file

Path

apps/web/test/env.test-d.ts

20 lines · 863 bytes · TypeScript

Last changed by

Merge build/comments-web-rest into mainoscabrielbefore adoption0eb1248

History of this file

Take it

The walk stopped after 200 commits: lines older than 678c8b8 point at it.

Merge build/comments-web-rest into mainoscabrielbefore adoption0eb1248

lines 1–2why, one step back
1// The web Worker's `Env` reaches the platform only through `PLATFORM` and holds no Artifacts binding,
2// so no code in a public page can reach a repo.

Merge build/614-env-service: deciders set write-only values for @sensitive items, the public sees the env shape, and checks see only placeholdersoscabrielbefore adoption678c8b8

lines 3–15why, one step back
3import { describe, expectTypeOf, it } from "vitest";
45describe("the web Worker's Env", () => {6 it("reaches the platform through the PLATFORM service binding", () => {7 expectTypeOf<Env>().toHaveProperty("PLATFORM");8 expectTypeOf<Env["PLATFORM"]>().toEqualTypeOf<Fetcher>();9 });1011 it("has no Artifacts binding, public or private", () => {12 expectTypeOf<Env>().not.toHaveProperty("ARTIFACTS");13 expectTypeOf<Env>().not.toHaveProperty("ARTIFACTS_PRIVATE");14 expectTypeOf<Extract<keyof Env, `ARTIFACTS${string}`>>().toBeNever();15 });

Name the ask an opening opened, say why a policy has not evaluated, and give code history a durable storeoscabrielbefore adoption51f046c

lines 16–19why, one step back
16
17 it("has no code-cache bucket: code history is the platform's to read and keep", () => {18 expectTypeOf<Env>().not.toHaveProperty("CODE_CACHE");19 });

Merge build/614-env-service: deciders set write-only values for @sensitive items, the public sees the env shape, and checks see only placeholdersoscabrielbefore adoption678c8b8

line 20why, one step back
20});