test_support

package
v0.1.10 Latest Latest
Warning

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

Go to latest
Published: Aug 1, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package test_support holds common testing utilities.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadRunfile

func LoadRunfile(path string) (*files.LoadedFile, error)

LoadRunfile tries to read a file using the loading rules of |RunfilePath|.

func RunfilePath

func RunfilePath(path string) (string, error)

RunfilePath tries to find a testdata file in a build system agnostic way, working for both Bazel environments and default Go ones.

func Runfiles

func Runfiles(dir string) ([]string, error)

Runfiles returns a list of all the runfiles associated with this test that contains |dir|. Typical use is Runfiles("testdata")

func TestTmpBase

func TestTmpBase() string

TestTmpDir returns a valid base string to be fed to os.MkdirTemp.

Types

This section is empty.

Jump to

Keyboard shortcuts

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