testutils

package
v0.9.1 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	GotaggerEmail = "Gotagger.Test@nowhere.com"
	GotaggerName  = "Gotagger Test"
)

Variables

This section is empty.

Functions

func CommitFile

func CommitFile(t T, repo *git.Repository, path, filename, message string, data []byte) plumbing.Hash

func CommitFiles

func CommitFiles(t T, repo *git.Repository, path, message string, files []FileCommit) plumbing.Hash

func CreateTag

func CreateTag(t T, r *git.Repository, name string)

func NewGitRepo

func NewGitRepo(t T) (repo *git.Repository, path string)

func SimpleGitRepo

func SimpleGitRepo(t T, repo *git.Repository, path string)

Types

type FileCommit

type FileCommit struct {
	Path     string
	Contents []byte
}

type T

type T interface {
	Errorf(string, ...interface{})
	FailNow()
	Fatal(...interface{})
	Fatalf(string, ...interface{})
	Helper()
	Log(args ...interface{})
	TempDir() string
}

Jump to

Keyboard shortcuts

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