jacamartst

package
v0.19.1 Latest Latest
Warning

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

Go to latest
Published: Apr 5, 2024 License: Apache-2.0, MIT, Apache-2.0, + 1 more Imports: 10 Imported by: 0

Documentation

Overview

Package jacamartst maintains shared test functionality.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AssertError added in v0.3.0

func AssertError(t *testing.T, err error)

func AssertNoError added in v0.3.0

func AssertNoError(t *testing.T, err error)

func LinuxRootSkip added in v0.12.0

func LinuxRootSkip(t *testing.T)

LinuxRootSkip skips current test is user is not root or not on linux.

func LinuxSkip added in v0.12.0

func LinuxSkip(t *testing.T)

LinuxSkip skips current test if not running on Linux.

func NewURL added in v0.3.0

func NewURL(u string) urlMatcher

NewURL implements the Mockgen Matcher interface to compare a URL string to a URL found in a http.request structure.

func WriteTmpFile added in v0.3.0

func WriteTmpFile(t *testing.T, prefix, contents string) string

WriteTmpFile creates a temporary file with the provided prefix and the contents. Full file path returned if successful.

Types

type ClosingBuffer added in v0.3.0

type ClosingBuffer struct {
	*bytes.Buffer
}

ClosingBuffer implements an io.ReaderCloser that always returns nil.

func (*ClosingBuffer) Close added in v0.3.0

func (cb *ClosingBuffer) Close() error

Jump to

Keyboard shortcuts

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