Spectre.Stack.Conformance (Spectre v0.3.0)

Copy Markdown View Source

Executable whole-Stack conformance gate for package ecosystems.

A package can conform in isolation while still colliding with another package, missing a requirement, declaring a conflict, or rejecting the current core release. run/2 normalizes every Contract V1 input and feeds the resulting installations through the same immutable Stack compiler used by Agents. Satellite libraries can therefore publish a tested compatibility matrix without pulling ExUnit into production code.

Summary

Functions

Returns the whole-Stack conformance contract version.

Validates a non-empty package matrix against the running Spectre release.

Types

entry()

@type entry() :: module() | {module(), Spectre.Stack.Package.t() | map() | keyword()}

Functions

contract_version()

@spec contract_version() :: pos_integer()

Returns the whole-Stack conformance contract version.

run(entries, opts \\ [])

@spec run(
  [entry()],
  keyword()
) :: {:ok, map()} | {:error, term()}

Validates a non-empty package matrix against the running Spectre release.

Entries may be installable modules or {module, manifest} pairs. The latter form is useful for fixtures and generated package manifests. Optional :configs is a map keyed by package id and must contain portable data.