mocks3

package
v56.0.3 Latest Latest
Warning

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

Go to latest
Published: Oct 18, 2023 License: MPL-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Resource

type Resource struct {
	Content         []byte
	ContentEncoding string
	ContentType     string
}

type S3

type S3 struct {
	// contains filtered or unexported fields
}

func New

func New(t *testing.T) *S3

func (*S3) Download

func (s3 *S3) Download(w http.ResponseWriter, r *http.Request)

func (*S3) FakeObject

func (s3 *S3) FakeObject(name string, contentType string, content []byte)

FakeObject makes a fake S3 object outside of the usual API flow. Note that mocktc creates object names on the form "/taskId/runId/name" for s3 artifacts, and that name is escaped with url.PathEscape.

func (*S3) RegisterService

func (s3 *S3) RegisterService(r *mux.Router)

func (*S3) Upload

func (s3 *S3) Upload(w http.ResponseWriter, r *http.Request)

Jump to

Keyboard shortcuts

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