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

cachetest

package
v0.9.1 Latest Latest
Warning

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

Go to latest
Published: Oct 17, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package cachetest 是 data 门面子包:CacheAside 实现契约测试套件(8 场景,含 -race)。

re-export 自 github.com/oekit/pkg/cache/cachetest:类型为泛型 type alias(与源包**完全同一类型**, 双向赋值互通);非泛型函数/变量经 var 引用同一函数值。源包新增导出符号时 本壳需同步(门面跟版税,data 门面化决策已接受)。

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Run

func Run[T any](t *testing.T, c Contract[T], factory func(t *testing.T, source pkgcache.SourceFunc[T]) pkgcache.CacheAside[T])

Run 跑完整契约场景(8 个子测试)。

Types

type Contract

type Contract[T any] = src.Contract[T]

func Comparable

func Comparable[T comparable]() Contract[T]

Comparable 返回可比较类型的现成 Contract。

Jump to

Keyboard shortcuts

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