IF Commons GitHub

check

Written to: 1 requirement: 1 proved, 0 partly, 0 failing, 0 with no test recorded. 0001-docs FR-001

What check finds (commons 0011-documentation FR-018), as a tagged union with one sentence for each case, and the place each is found: a file of the repository, a page of the site or an export. The generator gathers findings while it builds; check prints them and fails where there is one.

Source: commons/docs/src/check.ts

3 of 4 exports are imported by a test of the run. A test that imports an export may not call it or check what it returns.

Findinginterface
interface Finding

A problem and where it is.

MemberTypeWhat it is
wherestringThe file, page or export it is found in.
problemProblemWhat is wrong there.

Imported by 20 tests of the run (20 passed, 0 failed): the library's results

messagefunction
function message(p: Problem): string

The sentence a finding is printed with.

Imported by 4 tests of the run (4 passed, 0 failed): the library's results

Problemtypeno test imports it
type Problem = | { readonly kind: "undocumented"; readonly name: string } | { readonly kind: "no-about" } | { read… (1330 characters)
type Problem =
  | { readonly kind: "undocumented"; readonly name: string }
  | { readonly kind: "no-about" }
  | { readonly kind: "folder-missing"; readonly folder: string }
  | { readonly kind: "command-missing"; readonly command: string }
  | { readonly kind: "enforcer-missing"; readonly enforcer: string }
  | { readonly kind: "entry-point-missing"; readonly file: string }
  | { readonly kind: "example-missing"; readonly file: string }
  | { readonly kind: "unknown-spec"; readonly cite: string }
  | { readonly kind: "unknown-requirement"; readonly cite: string }
  | { readonly kind: "unknown-link"; readonly name: string }
  | { readonly kind: "undescribed"; readonly entity: string }
  | { readonly kind: "import-failed"; readonly error: string }
  | { readonly kind: "broken-link"; readonly href: string }
  | { readonly kind: "duplicate-spec"; readonly id: string }
  | { readonly kind: "diagram-undrawable"; readonly first: string }
  | { readonly kind: "book-part-empty"; readonly volume: string; readonly part: string }
  | { readonly kind: "evidence-unreadable"; readonly why: string }
  | { readonly kind: "test-requirement-unknown"; readonly requirement: string; readonly test: string }
  | { readonly kind: "retired-name"; readonly name: string }
  | { readonly kind: "forbidden-word"; readonly word: string };

What is wrong.

reportfunction
function report(found: readonly Finding[]): string[]

The findings as the lines check prints, sorted and each once.

Imported by 26 tests of the run (26 passed, 0 failed): the library's results

Titles, headings, exports, tables, columns and requirements. Esc closes.