notifytest

package
v0.3.19 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2026 License: MIT Imports: 4 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package notifytest holds the notification history helpers the shell's tests share: a store on a temporary file, and the history, the store and the popup list read back as pages and id sets.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func History

History is the first page of svc's history, newest first.

func IDs

func IDs(notifs []*notifications.Notification) map[uint32]bool

IDs is the set of the notifications' ids.

Types

type Store added in v0.3.14

type Store struct {
	// contains filtered or unexported fields
}

Store is a service's store as a test reads it back: through the service, whose writes reach the disk after its calls return.

func AttachStore

func AttachStore(t *testing.T, svc *notifications.Service) Store

AttachStore persists svc's history in a store on a temporary file, closed when the test ends; call it before the first notification.

func (Store) Stored added in v0.3.14

func (s Store) Stored(t *testing.T) []*notifications.Notification

Stored is the first page of what the store holds once every write the service queued so far has landed, newest first.

Jump to

Keyboard shortcuts

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