require

package
v0.0.0-...-66a6fc1 Latest Latest
Warning

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

Go to latest
Published: Nov 26, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AnyFeature

func AnyFeature(tb testing.TB, given *flag.IncludeExcludeStringSet, want ...string)

AnyFeature checks if at least one of the features are enabled.

See Features for more information.

func Binary

func Binary(tb testing.TB, binary string) string

Binary checks if `binary` exists in the same directory as the test binary. Returns full binary path if it exists, otherwise, skips the test.

func BinaryInPath

func BinaryInPath(tb testing.TB, binary string) string

Binary tries to locate `binary` in the PATH (or the current working directory), or the same the same directory as the currently-executing binary.

Returns full binary path if it exists, otherwise, skips the test.

func Features

func Features(tb testing.TB, given *flag.IncludeExcludeStringSet, want ...string)

Features checks the wanted features are present in given, and skips the test if any are missing or explicitly excluded. If the given set is empty, the function returns (by default, all features are enabled).

See flag.NewFeatureFlag and flag.IncludeExcludeStringSet for more details.

func File

func File(tb testing.TB, path, file string) string

File checks if `file` exists in `path`, and returns the full path if it exists. Otherwise, it skips the test.

Types

This section is empty.

Jump to

Keyboard shortcuts

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