testing

package
v1.23.0 Latest Latest
Warning

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

Go to latest
Published: Jun 12, 2023 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Harness

func Harness(t *testing.T, s oplock.Service)

Harness is a test harness for all implementations of oplock.Service. The test consists of firing multiple goroutines which attempt to acquire a lock over a single operation "test". Each acquisitions timestamp is pushed down a channel. When five lock acquisitions have occurred the test ensures that it took at-least a specified duration to do so (interval * (iterations - 1)). Also that acquisitions occurred in ascending timestamp order with a delta between each tick of at-least the configured interval.

Types

This section is empty.

Jump to

Keyboard shortcuts

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