testing

package
v0.0.0-...-ab56314 Latest Latest
Warning

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

Go to latest
Published: Jan 23, 2025 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Overview

Package testing provides helpers for testing gcetcbendorsement.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GoldenT

func GoldenT(t testing.TB, g *epb.VMGoldenMeasurement) []byte

GoldenT returns a serialized VMGoldenMeasurement while reporting errors to the test interface.

func Pipe

func Pipe() (io.ReadCloser, *os.File, error)

Pipe returns a pipe that closes the writer on first read.

Types

type FailWriter

type FailWriter struct{}

FailWriter is a writer that always returns an error.

func (FailWriter) Write

func (FailWriter) Write(b []byte) (int, error)

Write implements the Writer interface's Write method and returns an error.

Jump to

Keyboard shortcuts

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