conformance

package
v0.2.10 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 4, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package conformance is the document plane's shared behaviour suite: one table of assertions every document.Port implementation must satisfy, runnable against any of them.

It exists as a package rather than a test file because the suite is the contract. An implementation that cannot run it — a future port over object storage, a database, another server — has not been shown to be interchangeable with the ones that can, and "interchangeable" is the whole claim the document package makes. This mirrors testing/fstest in the standard library: the specification ships as something you can execute.

The write half of the conformance table: creating, replacing, deleting, and the preconditions each requires. Split from the read half only for size — both run against every Factory.

Index

Constants

View Source
const Seed = "1\t2\n3\t=A1+B1\n"

Seed is the document every behaviour starts from.

Variables

This section is empty.

Functions

func Seeded

func Seeded() map[string]string

Seeded is the fixture set every behaviour starts from.

Types

type Factory

type Factory func(t *testing.T, files map[string]string) document.Port

Factory builds a Port over a namespace seeded with the given documents. A factory returns a port with no shared state between calls, so one behaviour does not observe another's writes.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL