testutil

package
v0.0.28 Latest Latest
Warning

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

Go to latest
Published: Sep 6, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MustReadRunfile

func MustReadRunfile(path string) []byte

MustReadRunfile returns the contents of the specified runfile. Panic on error.

func MustRunfile

func MustRunfile(path string) string

MustRunfile returns the path to the specified runfile. Panic on error.

Types

type CleanupFunc

type CleanupFunc func()

CleanupFunc can be invoked to cleanup any temporary state.

func UnzipTemp

func UnzipTemp(path string) (string, CleanupFunc, error)

UnzipTemp unzips a zip archive to temporary path, and returns the path. The returned cleanup function should be invoked to cleanup any temporary state when it is no longer needed.

Jump to

Keyboard shortcuts

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