githubtesting

package
v0.31.1 Latest Latest
Warning

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

Go to latest
Published: Nov 17, 2020 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package githubtesting provides testing functionality for GitHub.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ArchiveReader

type ArchiveReader interface {
	// GetArchive gets the GitHub archive and untars it to the output directory path.
	//
	// The root directory within the tarball is stripped.
	// If the directory already exists, this is a no-op.
	//
	// Only use for testing.
	GetArchive(
		ctx context.Context,
		outputDirPath string,
		owner string,
		repository string,
		ref string,
	) error
}

ArchiveReader reads GitHub archives.

func NewArchiveReader

func NewArchiveReader(
	logger *zap.Logger,
	httpClient *http.Client,
) ArchiveReader

NewArchiveReader returns a new ArchiveReader.

Jump to

Keyboard shortcuts

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