testutils

package
v0.0.0-...-fb3792a Latest Latest
Warning

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

Go to latest
Published: Oct 9, 2020 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package testutils provides some useful helpers for buildozer/buildifer tests.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Diff

func Diff(b1, b2 []byte) ([]byte, error)

Diff returns the output of running diff on b1 and b2.

func FindTests

func FindTests(t *testing.T, directory, pattern string) ([]string, func())

FindTests finds all files matching the given pattern. It changes the working directory to `directory`, and returns a function to call to change back to the current directory. This allows tests to assert on alias finding between absolute and relative labels.

func Tdiff

func Tdiff(t *testing.T, a, b []byte)

Tdiff logs the Diff output to t.Error.

Types

This section is empty.

Jump to

Keyboard shortcuts

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