Help us shape the future of Go! Take the 2026 Go Developer Survey

testcertreceipt

package
v0.19.0 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2026 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Overview

Package testcertreceipt builds, for tests, a certificate-bound decision and the files the receipt commands read: the receipt (with and without its anchoring proof), the journal export, signed heads, the log's public key, and the certificate policy file with its trust anchor.

Index

Constants

This section is empty.

Variables

View Source
var DecidedAt = time.Date(2026, 10, 13, 12, 14, 3, 123000000, time.UTC)

DecidedAt is the signed time of the decision; the head that anchors it is stamped a minute later.

Functions

This section is empty.

Types

type Fixture

type Fixture struct {
	Dir string
	// Receipt holds the anchored receipt, NoProof the same receipt without its anchoring proof, and
	// Bare a bare-key receipt of another decision.
	Receipt, NoProof string
	// ReceiptLate is the receipt anchored under a head an hour later than the one in Heads.
	ReceiptLate string
	Journal     string
	// Heads are the signed heads (before and after the decision), HeadsBefore only the first.
	Heads, HeadsBefore string
	// Policy is the certificate policy file; OtherPolicy trusts another root.
	Policy, OtherPolicy string
	// LogKey is the log's public key text.
	LogKey string
	// Identifier and DisplayName are what the certificate says; AnchoredAt is the covering head's time.
	Identifier, DisplayName string
	AnchoredAt              time.Time
	LeafHash                string
}

Fixture is a certificate-bound approval by "alice" and the files that describe it.

func New

func New(t testing.TB) *Fixture

New builds the fixture in a fresh temporary directory.

Jump to

Keyboard shortcuts

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