shortcuttest

package
v0.0.0-...-71cd2e8 Latest Latest
Warning

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

Go to latest
Published: May 2, 2024 License: BSD-3-Clause Imports: 10 Imported by: 0

Documentation

Overview

Package shortcuttest has common code for tests of implementations of shortcut.Store.

Index

Constants

This section is empty.

Variables

View Source
var SubTests = map[string]SubTestFunction{
	"Shortcut_GetAll":         GetAll,
	"Shortcut_InsertGet":      InsertGet,
	"Shortcut_GetNonExistent": GetNonExistent,
}

SubTests are all the subtests we have for regression.Store.

Functions

func GetAll

func GetAll(t *testing.T, store shortcut.Store)

Shortcut_GetAll tests that GetAll produces a channel of all the shortcuts in the database.

func GetNonExistent

func GetNonExistent(t *testing.T, store shortcut.Store)

Shortcut_GetNonExistent tests that we fail when retrieving an unknown shortcut.

func InsertGet

func InsertGet(t *testing.T, store shortcut.Store)

Shortcut_InsertGet does the core testing of an instance of shortcut.Store.

Types

type SubTestFunction

type SubTestFunction func(t *testing.T, store shortcut.Store)

SubTestFunction is a func we will call to test one aspect of an implementation of regression.Store.

Jump to

Keyboard shortcuts

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