flux: github.com/weaveworks/flux/pkg/git/gittest Index | Files

package gittest

import "github.com/weaveworks/flux/pkg/git/gittest"


Package Files



var TestConfig git.Config = git.Config{
    Branch:    "master",
    UserName:  "example",
    UserEmail: "example@example.com",
    NotesRef:  "fluxtest",

func Checkout Uses

func Checkout(t *testing.T) (*git.Checkout, func())

Checkout makes a standard repo, clones it, and returns the clone with a cleanup function.

func CheckoutWithConfig Uses

func CheckoutWithConfig(t *testing.T, config git.Config, syncTag string) (*git.Checkout, *git.Repo, func())

CheckoutWithConfig makes a standard repo, clones it, and returns the clone, the original repo, and a cleanup function.

func Repo Uses

func Repo(t *testing.T, files map[string]string) (*git.Repo, func())

Repo creates a new clone-able git repo, pre-populated with some kubernetes files and a few commits. Also returns a cleanup func to clean up after.

func Workloads Uses

func Workloads() (res []resource.ID)

Workloads is a shortcut to getting the names of the workloads (NB not all resources, just the workloads) represented in the test files.

Package gittest imports 8 packages (graph). Updated 2020-09-10. Refresh now. Tools for package owners.