ostest

package
v0.5.4 Latest Latest
Warning

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

Go to latest
Published: Aug 31, 2022 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Chdir

func Chdir(t test.T, dir string)

Chdir changes the working directory to the given directory for the duration of the current test.

The old working directory is restored when the test exits.

func Setenv

func Setenv(t test.T, k, v string)

Setenv changes an environment variable's value for the duration of the current test.

It automatically restores the previous value, if any, after the test finishes.

func Unsetenv

func Unsetenv(t test.T, k string)

Unsetenv unsets the given environment variable for the duration of the current test.

It automatically restores the previous value, if any, after the test finishes.

Types

This section is empty.

Jump to

Keyboard shortcuts

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