repotest

package
v2.2.0 Latest Latest
Warning

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

Go to latest
Published: Mar 30, 2022 License: GPL-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Opt

type Opt func(*repoOptions)

func WithKeepTmpDir

func WithKeepTmpDir() Opt

func WithNewDB

func WithNewDB() Opt

WithNewDB create a new database with an unique name and use it for the baur repository.

type Repo

type Repo struct {
	AppCfgs             []*cfg.App
	Dir                 string
	FilecopyArtifactDir string
}

func CreateBaurRepository

func CreateBaurRepository(t *testing.T, opts ...Opt) *Repo

CreateBaurRepository creates a new baur repository in a temporary directory and a new postgres database with a unique name. The funcion changes the current working directory to the created repository directory.

func (*Repo) CreateAppWithNoOutputs

func (r *Repo) CreateAppWithNoOutputs(t *testing.T, appName string) *cfg.App

func (*Repo) CreateAppWithoutTasks

func (r *Repo) CreateAppWithoutTasks(t *testing.T) *cfg.App

func (*Repo) CreateSimpleApp

func (r *Repo) CreateSimpleApp(t *testing.T) *cfg.App

func (*Repo) TaskIDs

func (r *Repo) TaskIDs() []string

TaskIDs returns the tasks ids (<AppName>.<TaskName>) of all tasks in the AppCfgs slice

func (*Repo) WriteAdditionalFileContents

func (r *Repo) WriteAdditionalFileContents(t *testing.T, appName, fileName, contents string) *digest.Digest

Jump to

Keyboard shortcuts

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