DocShell.Presentation.Conformance (DocShell v0.5.0)

Copy Markdown View Source

Shared fixtures and semantic snapshots for independent site renderers.

HTML byte equality is deliberately absent. A renderer adapter records the portable semantics observed in its hosted or static surface; compare/2 checks content identity, routes, headings, links, landmarks, accessible names and ordinary actions while allowing an honest unavailable static state for a live-only action.

Summary

Functions

Compares hosted and static surfaces, including honest live-action degradation.

Loads and validates the bundled renderer-conformance fixture.

Returns the bundled renderer-conformance fixture path.

Builds a validated semantic surface from renderer-observed page records.

Functions

compare(hosted, static)

Compares hosted and static surfaces, including honest live-action degradation.

fixture()

@spec fixture() :: {:ok, map()} | {:error, term()}

Loads and validates the bundled renderer-conformance fixture.

fixture_path()

@spec fixture_path() :: Path.t()

Returns the bundled renderer-conformance fixture path.

surface(site, mode, pages)

@spec surface(DocShell.Presentation.Site.t(), :hosted | :static, map()) ::
  {:ok, DocShell.Presentation.Conformance.Surface.t()} | {:error, term()}

Builds a validated semantic surface from renderer-observed page records.