Documentation ¶
Index ¶
- Constants
- func GetPathAndWorkingDir(content *testkube.TestContent, dataDir string) (path, workingDir string, err error)
- type ContentFetcher
- type CopyFilesPlacer
- type Fetcher
- func (f Fetcher) CalculateGitContentType(repo testkube.Repository) (string, error)
- func (f Fetcher) Fetch(content *testkube.TestContent) (path string, err error)
- func (f Fetcher) FetchGit(repo *testkube.Repository) (path string, err error)
- func (f Fetcher) FetchGitDir(repo *testkube.Repository) (path string, err error)
- func (f Fetcher) FetchGitFile(repo *testkube.Repository) (path string, err error)
- func (f Fetcher) FetchString(str string) (path string, err error)
- func (f Fetcher) FetchURI(uri string) (path string, err error)
- type GitDirFetcher
- type GitFetcher
- type GitFileFetcher
- type StringFetcher
- type URIFetcher
Constants ¶
const (
UploadsFolder = "/data/uploads/"
)
Variables ¶
This section is empty.
Functions ¶
func GetPathAndWorkingDir ¶ added in v1.11.25
func GetPathAndWorkingDir(content *testkube.TestContent, dataDir string) (path, workingDir string, err error)
GetPathAndWorkingDir returns path to git based file or dir saved in local temp directory and working dir
Types ¶
type ContentFetcher ¶
type ContentFetcher interface { StringFetcher URIFetcher GitDirFetcher GitFileFetcher GitFetcher Fetch(content *testkube.TestContent) (path string, err error) // Deprecated: use git instead CalculateGitContentType(repo testkube.Repository) (string, error) }
ContentFetcher is interface container for all possible fetchers
type CopyFilesPlacer ¶ added in v1.6.35
type CopyFilesPlacer struct {
// contains filtered or unexported fields
}
CopyFilesPlacer takes care of downloading the file into the execution
func NewCopyFilesPlacer ¶ added in v1.6.35
func NewCopyFilesPlacer(client storage.Client) *CopyFilesPlacer
func (CopyFilesPlacer) PlaceFiles ¶ added in v1.6.35
func (p CopyFilesPlacer) PlaceFiles(ctx context.Context, testName, executionBucket string)
PlaceFiles downloads the files from minio and places them into the /data/uploads directory. A warning will be shown in case there was an error placing the files.
type Fetcher ¶
type Fetcher struct {
// contains filtered or unexported fields
}
func NewFetcher ¶
NewFetcher returns new file/dir fetcher based on given directory path
func (Fetcher) CalculateGitContentType ¶ added in v1.9.14
func (f Fetcher) CalculateGitContentType(repo testkube.Repository) (string, error)
CalculateGitContentType returns the type of the git test source Deprecated: use git instead
func (Fetcher) Fetch ¶
func (f Fetcher) Fetch(content *testkube.TestContent) (path string, err error)
func (Fetcher) FetchGit ¶ added in v1.9.29
func (f Fetcher) FetchGit(repo *testkube.Repository) (path string, err error)
FetchGit returns path to git based file or dir saved in local temp directory
func (Fetcher) FetchGitDir ¶
func (f Fetcher) FetchGitDir(repo *testkube.Repository) (path string, err error)
FetchGitDir returns path to locally checked out git repo with partial path
func (Fetcher) FetchGitFile ¶
func (f Fetcher) FetchGitFile(repo *testkube.Repository) (path string, err error)
FetchGitFile returns path to git based file saved in local temp directory
func (Fetcher) FetchString ¶
FetchString stores string content as file
type GitDirFetcher ¶
type GitDirFetcher interface {
FetchGitDir(repo *testkube.Repository) (path string, err error)
}
GitDirFetcher interface for fetching GitDir based content to local directory Deprecated: use GitFetcher instead
type GitFetcher ¶ added in v1.9.29
type GitFetcher interface {
FetchGit(repo *testkube.Repository) (path string, err error)
}
GitFetcher interface for fetching GitFile or GitDir based content to local file
type GitFileFetcher ¶
type GitFileFetcher interface {
FetchGitFile(repo *testkube.Repository) (path string, err error)
}
GitFileFetcher interface for fetching GitDir based content to local file Deprecated: use GitFetcher instead
type StringFetcher ¶
StringFetcher interface for fetching string based content to file
type URIFetcher ¶
URIFetcher interface for fetching URI based content to file