Test pages
The pages Pagez must build, one folder each, written before the compiler to pin down what it
does. Each folder holds an index.md and whatever sits beside it, such as @x-tag.html files, an
frame.html, a style.css, scripts, images or a node_modules.
- A page opens with a
<!-- Expect: … -->comment, which says what it builds to, or where it fails. Open:in that comment marks what the design hasn't decided yet.grep -rn "Open:" tests/pageslists them all, and each is settled in the docs before the compiler needs it.- A folder named
error-…is a page that must fail, at the place its comment names. - A small element used once is defined in its page, as an author would write it. It's in a file where the file is the point, or where it's shared or has behavior.
- Two pages that must build to the same output say so, as
element-in-pageandelement-filedo.
tests/pages.test.ts builds each page and compares it with its snapshot in
tests/snapshots/<page>/page.html, or an error-… page with its error.txt, each reviewed as it
changes. A page that warns has its warnings in warnings.txt. What only a build shows, such as what Vite bundles, is in tests/vite.test.ts.
The cases
Each case is cited by the rule it holds, in pages and elements. Each error-… case fails with an id from the Errors table, its last word in error.txt. tests/docs.test.ts keeps the docs and the cases in line.
No prose yet
element-attr-expression/ · element-behavior/ · element-behavior-only/ · element-data-import/ · element-file/ · element-file-named/ · element-in-folder/ · element-in-page/ · element-nested/ · element-slot-fallback/ · element-template-script/ · element-unused/ · error-browser-import/ · error-browser-node/ · error-expression-call/ · error-expression-missing/ · error-expression-scope/ · error-expression-value/ · error-frame-two-slots/ · error-image-no-url/ · error-in-page-definition/ · error-inline-block/ · error-module-load/ · error-name-duplicate-file/ · error-name-duplicate-page/ · error-name-mismatch/ · error-name-no-hyphen/ · error-name-reserved/ · error-name-two-files/ · error-name-uppercase/ · error-package-missing/ · error-relative-missing/ · error-style-import-package/ · error-style-missing/ · error-template-object/ · error-template-render/ · expressions/ · expressions-dotted-key/ · frame/ · frame-elements/ · head/ · markz-warnings/ · native-tags/ · no-metadata/ · page-css/ · page-css-wins/ · plain/ · prose/ · raw-html/ · references-css/ · references-image/ · references-link/ · references-package/ · references-relative-script/ · references-shared-import/ · references-url-import/ · stories/ · style-css/ · style-css-elements/ · third-party-component/ · undefined-tag/