storetest

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package storetest is the conformance suite every [connectionforge.Store] and [connectionforge.Leaser] must pass. A store's own tests call it with a constructor:

func TestConformance(t *testing.T) {
	storetest.Run(t, func(t *testing.T) connectionforge.Store { return newStore(t) })
}

It checks owner isolation on every method, compare-and-swap on connections and credentials (including under concurrency), the transition table, cascade on delete, ordering, idempotence, and that returned records are copies.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Run

func Run(t *testing.T, newStore func(t *testing.T) cf.Store)

Run runs the store suite. newStore returns an empty store for each subtest.

func RunLeaser

func RunLeaser(t *testing.T, newLeaser func(t *testing.T) cf.Leaser)

RunLeaser runs the leaser suite. newLeaser returns a fresh leaser.

Types

This section is empty.

Jump to

Keyboard shortcuts

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