test

package
v1.32.2-hotfix.1 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2020 License: BSD-2-Clause Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CloneColor

func CloneColor(datum *image.Color) *image.Color

func CloneContentAttributes

func CloneContentAttributes(datum *image.ContentAttributes) *image.ContentAttributes

func CloneImage

func CloneImage(datum *image.Image) *image.Image

func CloneImageArray

func CloneImageArray(datum image.ImageArray) image.ImageArray

func CloneMetadata

func CloneMetadata(datum *image.Metadata) *image.Metadata

func CloneRendition

func CloneRendition(datum *image.Rendition) *image.Rendition

func MatchContentAttributes

func MatchContentAttributes(datum *image.ContentAttributes) gomegaTypes.GomegaMatcher

func MatchImage

func MatchImage(datum *image.Image) gomegaTypes.GomegaMatcher

func MatchImageArray

func MatchImageArray(datum image.ImageArray) gomegaTypes.GomegaMatcher

func NewObjectFromContentAttributes

func NewObjectFromContentAttributes(datum *image.ContentAttributes, objectFormat test.ObjectFormat) map[string]interface{}

func NewObjectFromFilter

func NewObjectFromFilter(datum *image.Filter, objectFormat test.ObjectFormat) map[string]interface{}

func NewObjectFromImage

func NewObjectFromImage(datum *image.Image, objectFormat test.ObjectFormat) map[string]interface{}

func NewObjectFromMetadata

func NewObjectFromMetadata(datum *image.Metadata, objectFormat test.ObjectFormat) map[string]interface{}

func NewObjectFromRendition

func NewObjectFromRendition(datum *image.Rendition, objectFormat test.ObjectFormat) map[string]interface{}

func RandomColor

func RandomColor() *image.Color

func RandomContent

func RandomContent() *image.Content

func RandomContentAttributes

func RandomContentAttributes() *image.ContentAttributes

func RandomContentBytes

func RandomContentBytes() []byte

func RandomContentBytesFromDimensionsAndMediaType

func RandomContentBytesFromDimensionsAndMediaType(width int, height int, mediaType string) []byte

func RandomContentBytesFromMediaType

func RandomContentBytesFromMediaType(mediaType string) []byte

func RandomContentFromDimensions

func RandomContentFromDimensions(width int, height int) *image.Content

func RandomContentID

func RandomContentID() string

func RandomContentIntent

func RandomContentIntent() string

func RandomContentIntents

func RandomContentIntents() []string

func RandomFilter

func RandomFilter() *image.Filter

func RandomGeneration

func RandomGeneration() int

func RandomHeight

func RandomHeight() int

func RandomID

func RandomID() string

func RandomImage

func RandomImage() *image.Image

func RandomImageArray

func RandomImageArray(minimumLength int, maximumLength int) image.ImageArray

func RandomMediaType

func RandomMediaType() string

func RandomMetadata

func RandomMetadata() *image.Metadata

func RandomMode

func RandomMode() string

func RandomName

func RandomName() string

func RandomQuality

func RandomQuality() int

func RandomRendition

func RandomRendition() *image.Rendition

func RandomRenditionString

func RandomRenditionString() string

func RandomRenditionStrings

func RandomRenditionStrings() []string

func RandomRenditionsID

func RandomRenditionsID() string

func RandomStatus

func RandomStatus() string

func RandomStatuses

func RandomStatuses() []string

func RandomWidth

func RandomWidth() int

Types

type Client

type Client struct {
	ListInvocations                int
	ListInputs                     []ListInput
	ListStub                       func(ctx context.Context, userID string, filter *image.Filter, pagination *page.Pagination) (image.ImageArray, error)
	ListOutputs                    []ListOutput
	ListOutput                     *ListOutput
	CreateInvocations              int
	CreateInputs                   []CreateInput
	CreateStub                     func(ctx context.Context, userID string, metadata *image.Metadata, contentIntent string, content *image.Content) (*image.Image, error)
	CreateOutputs                  []CreateOutput
	CreateOutput                   *CreateOutput
	CreateWithMetadataInvocations  int
	CreateWithMetadataInputs       []CreateWithMetadataInput
	CreateWithMetadataStub         func(ctx context.Context, userID string, metadata *image.Metadata) (*image.Image, error)
	CreateWithMetadataOutputs      []CreateWithMetadataOutput
	CreateWithMetadataOutput       *CreateWithMetadataOutput
	CreateWithContentInvocations   int
	CreateWithContentInputs        []CreateWithContentInput
	CreateWithContentStub          func(ctx context.Context, userID string, contentIntent string, content *image.Content) (*image.Image, error)
	CreateWithContentOutputs       []CreateWithContentOutput
	CreateWithContentOutput        *CreateWithContentOutput
	DeleteAllInvocations           int
	DeleteAllInputs                []string
	DeleteAllStub                  func(ctx context.Context, id string) error
	DeleteAllOutputs               []error
	DeleteAllOutput                *error
	GetInvocations                 int
	GetInputs                      []string
	GetStub                        func(ctx context.Context, id string) (*image.Image, error)
	GetOutputs                     []GetOutput
	GetOutput                      *GetOutput
	GetMetadataInvocations         int
	GetMetadataInputs              []string
	GetMetadataStub                func(ctx context.Context, id string) (*image.Metadata, error)
	GetMetadataOutputs             []GetMetadataOutput
	GetMetadataOutput              *GetMetadataOutput
	GetContentInvocations          int
	GetContentInputs               []GetContentInput
	GetContentStub                 func(ctx context.Context, id string, mediaType *string) (*image.Content, error)
	GetContentOutputs              []GetContentOutput
	GetContentOutput               *GetContentOutput
	GetRenditionContentInvocations int
	GetRenditionContentInputs      []GetRenditionContentInput
	GetRenditionContentStub        func(ctx context.Context, id string, rendition *image.Rendition) (*image.Content, error)
	GetRenditionContentOutputs     []GetRenditionContentOutput
	GetRenditionContentOutput      *GetRenditionContentOutput
	PutMetadataInvocations         int
	PutMetadataInputs              []PutMetadataInput
	PutMetadataStub                func(ctx context.Context, id string, condition *request.Condition, metadata *image.Metadata) (*image.Image, error)
	PutMetadataOutputs             []PutMetadataOutput
	PutMetadataOutput              *PutMetadataOutput
	PutContentInvocations          int
	PutContentInputs               []PutContentInput
	PutContentStub                 func(ctx context.Context, id string, condition *request.Condition, contentIntent string, content *image.Content) (*image.Image, error)
	PutContentOutputs              []PutContentOutput
	PutContentOutput               *PutContentOutput
	DeleteInvocations              int
	DeleteInputs                   []DeleteInput
	DeleteStub                     func(ctx context.Context, id string, condition *request.Condition) (bool, error)
	DeleteOutputs                  []DeleteOutput
	DeleteOutput                   *DeleteOutput
}

func NewClient

func NewClient() *Client

func (*Client) AssertOutputsEmpty

func (c *Client) AssertOutputsEmpty()

func (*Client) Create

func (c *Client) Create(ctx context.Context, userID string, metadata *image.Metadata, contentIntent string, content *image.Content) (*image.Image, error)

func (*Client) CreateWithContent

func (c *Client) CreateWithContent(ctx context.Context, userID string, contentIntent string, content *image.Content) (*image.Image, error)

func (*Client) CreateWithMetadata

func (c *Client) CreateWithMetadata(ctx context.Context, userID string, metadata *image.Metadata) (*image.Image, error)

func (*Client) Delete

func (c *Client) Delete(ctx context.Context, id string, condition *request.Condition) (bool, error)

func (*Client) DeleteAll

func (c *Client) DeleteAll(ctx context.Context, userID string) error

func (*Client) Get

func (c *Client) Get(ctx context.Context, id string) (*image.Image, error)

func (*Client) GetContent

func (c *Client) GetContent(ctx context.Context, id string, mediaType *string) (*image.Content, error)

func (*Client) GetMetadata

func (c *Client) GetMetadata(ctx context.Context, id string) (*image.Metadata, error)

func (*Client) GetRenditionContent

func (c *Client) GetRenditionContent(ctx context.Context, id string, rendition *image.Rendition) (*image.Content, error)

func (*Client) List

func (c *Client) List(ctx context.Context, userID string, filter *image.Filter, pagination *page.Pagination) (image.ImageArray, error)

func (*Client) PutContent

func (c *Client) PutContent(ctx context.Context, id string, condition *request.Condition, contentIntent string, content *image.Content) (*image.Image, error)

func (*Client) PutMetadata

func (c *Client) PutMetadata(ctx context.Context, id string, condition *request.Condition, metadata *image.Metadata) (*image.Image, error)

type CreateInput

type CreateInput struct {
	UserID        string
	Metadata      *image.Metadata
	ContentIntent string
	Content       *image.Content
}

type CreateOutput

type CreateOutput struct {
	Image *image.Image
	Error error
}

type CreateWithContentInput

type CreateWithContentInput struct {
	UserID        string
	ContentIntent string
	Content       *image.Content
}

type CreateWithContentOutput

type CreateWithContentOutput struct {
	Image *image.Image
	Error error
}

type CreateWithMetadataInput

type CreateWithMetadataInput struct {
	UserID   string
	Metadata *image.Metadata
}

type CreateWithMetadataOutput

type CreateWithMetadataOutput struct {
	Image *image.Image
	Error error
}

type DeleteInput

type DeleteInput struct {
	ID        string
	Condition *request.Condition
}

type DeleteOutput

type DeleteOutput struct {
	Deleted bool
	Error   error
}

type GetContentInput

type GetContentInput struct {
	ID        string
	MediaType *string
}

type GetContentOutput

type GetContentOutput struct {
	Content *image.Content
	Error   error
}

type GetMetadataOutput

type GetMetadataOutput struct {
	Metadata *image.Metadata
	Error    error
}

type GetOutput

type GetOutput struct {
	Image *image.Image
	Error error
}

type GetRenditionContentInput

type GetRenditionContentInput struct {
	ID        string
	Rendition *image.Rendition
}

type GetRenditionContentOutput

type GetRenditionContentOutput struct {
	Content *image.Content
	Error   error
}

type ListInput

type ListInput struct {
	UserID     string
	Filter     *image.Filter
	Pagination *page.Pagination
}

type ListOutput

type ListOutput struct {
	ImageArray image.ImageArray
	Error      error
}

type PutContentInput

type PutContentInput struct {
	ID            string
	Condition     *request.Condition
	ContentIntent string
	Content       *image.Content
}

type PutContentOutput

type PutContentOutput struct {
	Image *image.Image
	Error error
}

type PutMetadataInput

type PutMetadataInput struct {
	ID        string
	Condition *request.Condition
	Metadata  *image.Metadata
}

type PutMetadataOutput

type PutMetadataOutput struct {
	Image *image.Image
	Error error
}

Jump to

Keyboard shortcuts

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