Skip to content

docs(testing): the scripts' pure halves, and why they moved out - #145

Merged
viztor merged 1 commit into
mainfrom
docs/testing-scripts
Oct 31, 2026
Merged

viztor merged 1 commit into
mainfrom
docs/testing-scripts

Conversation

@viztor

@viztor viztor commented Oct 31, 2026

Copy link
Copy Markdown
Owner

Three gates are scripts, and a script that runs at import time cannot be tested. This session moved the decision out of three of them; this records which, and what each test holds:

script the decision, extracted what the test holds
generate-go-limits.ts scripts/go-limits-html.ts which table is an allowance (by header, not position), the refusal when the page carries none, and the round trip through the real parser
check-vendor-version.ts scripts/vendor-version.ts the constant is found, and "read nothing" is distinguishable from "passed"
publish-scoped.ts scripts/wrapper-forwarder.ts the retired alias's entry links against the built barrel in a real Node process

Two of the three had already passed while wrong — the version gate twice, and the Go-limits reader when the docs moved to HTML — which is the argument: a decision that lives in a top-level-await script is exercised only by the vendor's schedule.

It is the same pattern the utils/ gate enforces inside src/, applied to the one place it had not reached.

Three gates are scripts, and a script that runs at import time cannot be tested.
This session moved the decision out of three of them; the table records which,
and what each test holds:

- `generate-go-limits.ts` → `scripts/go-limits-html.ts`: which table is an
  allowance (by header, not position), the refusal when the page carries none,
  and the round trip through the real parser;
- `check-vendor-version.ts` → `scripts/vendor-version.ts`: the constant is
  found, and "read nothing" is distinguishable from "passed";
- `publish-scoped.ts` → `scripts/wrapper-forwarder.ts`: the retired alias's
  entry LINKS against the built barrel in a real Node process.

Two of the three had already passed while wrong — the version gate twice, and
the Go-limits reader when the docs moved to HTML — which is the argument:
**a decision that lives in a top-level-await script is exercised only by the
vendor's schedule.**

It is the same pattern the `utils/` gate enforces inside `src/`, applied to the
one place it had not reached.
@viztor
viztor merged commit af4e1ff into main Oct 31, 2026
3 checks passed
@viztor
viztor deleted the docs/testing-scripts branch October 31, 2026 17:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant