mocksqs: github.com/elliotchance/mocksqs Index | Files

package mocksqs

import "github.com/elliotchance/mocksqs"

Index

Package Files

attributes.go create.go dead_letter.go delete_message.go delete_queue.go errors.go list.go message.go permission.go purge.go queue.go receive.go send.go sqs.go tags.go url.go util.go visibility.go

func CreateQueueURL Uses

func CreateQueueURL(name string) string

CreateQueueURL will generate a valid SQS queue URL with the provided queue name.

type Message Uses

type Message struct {
    sqs.Message
    VisibleAfter time.Time
    ReceiveCount int64
}

type Queue Uses

type Queue struct {
    URL string

    // OnEmptyQueue is triggered after the last message is deleted from the
    // queue. If a queue becomes empty multiple times then this is triggered
    // each time.
    OnEmptyQueue func()
    // contains filtered or unexported fields
}

type SQS Uses

type SQS struct {
    sync.RWMutex

    // SimulateHTTPLatency when enabled will add a sleep between 20 and 100
    // milliseconds to each call that would otherwise need to make a HTTP
    // request with a real SQS client.
    SimulateHTTPLatency bool
    // contains filtered or unexported fields
}

func New Uses

func New() *SQS

New creates a new SQS service that contains no queues.

func NewWithQueues Uses

func NewWithQueues(queues map[string][]string) *SQS

NewWithQueues create a new SQS service with prepopulated queues and messages.

The map key is the queue URL. Each queue can contain zero or more messages. All of the messages on the queues will be immediately visible.

func (*SQS) AddPermission Uses

func (client *SQS) AddPermission(*sqs.AddPermissionInput) (*sqs.AddPermissionOutput, error)

AddPermission is not implemented. It will panic in all cases.

func (*SQS) AddPermissionRequest Uses

func (client *SQS) AddPermissionRequest(*sqs.AddPermissionInput) (*request.Request, *sqs.AddPermissionOutput)

AddPermissionRequest is not implemented. It will panic in all cases.

func (*SQS) AddPermissionWithContext Uses

func (client *SQS) AddPermissionWithContext(aws.Context, *sqs.AddPermissionInput, ...request.Option) (*sqs.AddPermissionOutput, error)

AddPermissionWithContext is not implemented. It will panic in all cases.

func (*SQS) ChangeMessageVisibility Uses

func (client *SQS) ChangeMessageVisibility(input *sqs.ChangeMessageVisibilityInput) (*sqs.ChangeMessageVisibilityOutput, error)

func (*SQS) ChangeMessageVisibilityBatch Uses

func (client *SQS) ChangeMessageVisibilityBatch(*sqs.ChangeMessageVisibilityBatchInput) (*sqs.ChangeMessageVisibilityBatchOutput, error)

ChangeMessageVisibilityBatch is not implemented. It will panic in all cases.

func (*SQS) ChangeMessageVisibilityBatchRequest Uses

func (client *SQS) ChangeMessageVisibilityBatchRequest(*sqs.ChangeMessageVisibilityBatchInput) (*request.Request, *sqs.ChangeMessageVisibilityBatchOutput)

ChangeMessageVisibilityBatchRequest is not implemented. It will panic in all cases.

func (*SQS) ChangeMessageVisibilityBatchWithContext Uses

func (client *SQS) ChangeMessageVisibilityBatchWithContext(aws.Context, *sqs.ChangeMessageVisibilityBatchInput, ...request.Option) (*sqs.ChangeMessageVisibilityBatchOutput, error)

ChangeMessageVisibilityBatchWithContext is not implemented. It will panic in all cases.

func (*SQS) ChangeMessageVisibilityRequest Uses

func (client *SQS) ChangeMessageVisibilityRequest(*sqs.ChangeMessageVisibilityInput) (*request.Request, *sqs.ChangeMessageVisibilityOutput)

ChangeMessageVisibilityRequest is not implemented. It will panic in all cases.

func (*SQS) ChangeMessageVisibilityWithContext Uses

func (client *SQS) ChangeMessageVisibilityWithContext(aws.Context, *sqs.ChangeMessageVisibilityInput, ...request.Option) (*sqs.ChangeMessageVisibilityOutput, error)

ChangeMessageVisibilityWithContext is not implemented. It will panic in all cases.

func (*SQS) CreateQueue Uses

func (client *SQS) CreateQueue(input *sqs.CreateQueueInput) (*sqs.CreateQueueOutput, error)

CreateQueue is partially implemented. The following fields are not implemented:

- Attributes: DelaySeconds, MaximumMessageSize, MessageRetentionPeriod, Policy, ReceiveMessageWaitTimeSeconds, RedrivePolicy, VisibilityTimeout, KmsMasterKeyId, KmsDataKeyReusePeriodSeconds, FifoQueue, ContentBasedDeduplication

- Tags

func (*SQS) CreateQueueRequest Uses

func (client *SQS) CreateQueueRequest(*sqs.CreateQueueInput) (*request.Request, *sqs.CreateQueueOutput)

CreateQueueRequest is not implemented. It will panic in all cases.

func (*SQS) CreateQueueWithContext Uses

func (client *SQS) CreateQueueWithContext(aws.Context, *sqs.CreateQueueInput, ...request.Option) (*sqs.CreateQueueOutput, error)

CreateQueueWithContext is not implemented. It will panic in all cases.

func (*SQS) DeleteMessage Uses

func (client *SQS) DeleteMessage(input *sqs.DeleteMessageInput) (*sqs.DeleteMessageOutput, error)

DeleteMessage is fully supported.

func (*SQS) DeleteMessageBatch Uses

func (client *SQS) DeleteMessageBatch(input *sqs.DeleteMessageBatchInput) (*sqs.DeleteMessageBatchOutput, error)

DeleteMessageBatch is fully supported.

func (*SQS) DeleteMessageBatchRequest Uses

func (client *SQS) DeleteMessageBatchRequest(*sqs.DeleteMessageBatchInput) (*request.Request, *sqs.DeleteMessageBatchOutput)

DeleteMessageBatchRequest is not implemented. It will panic in all cases.

func (*SQS) DeleteMessageBatchWithContext Uses

func (client *SQS) DeleteMessageBatchWithContext(aws.Context, *sqs.DeleteMessageBatchInput, ...request.Option) (*sqs.DeleteMessageBatchOutput, error)

DeleteMessageBatchWithContext is not implemented. It will panic in all cases.

func (*SQS) DeleteMessageRequest Uses

func (client *SQS) DeleteMessageRequest(*sqs.DeleteMessageInput) (*request.Request, *sqs.DeleteMessageOutput)

DeleteMessageRequest is not implemented. It will panic in all cases.

func (*SQS) DeleteMessageWithContext Uses

func (client *SQS) DeleteMessageWithContext(aws.Context, *sqs.DeleteMessageInput, ...request.Option) (*sqs.DeleteMessageOutput, error)

DeleteMessageWithContext is not implemented. It will panic in all cases.

func (*SQS) DeleteQueue Uses

func (client *SQS) DeleteQueue(input *sqs.DeleteQueueInput) (*sqs.DeleteQueueOutput, error)

DeleteQueue is fully supported.

func (*SQS) DeleteQueueRequest Uses

func (client *SQS) DeleteQueueRequest(*sqs.DeleteQueueInput) (*request.Request, *sqs.DeleteQueueOutput)

DeleteQueueRequest is not implemented. It will panic in all cases.

func (*SQS) DeleteQueueWithContext Uses

func (client *SQS) DeleteQueueWithContext(aws.Context, *sqs.DeleteQueueInput, ...request.Option) (*sqs.DeleteQueueOutput, error)

DeleteQueueWithContext is not implemented. It will panic in all cases.

func (*SQS) GetQueue Uses

func (client *SQS) GetQueue(queueURL string) *Queue

func (*SQS) GetQueueAttributes Uses

func (client *SQS) GetQueueAttributes(*sqs.GetQueueAttributesInput) (*sqs.GetQueueAttributesOutput, error)

GetQueueAttributes is not implemented. It will panic in all cases.

func (*SQS) GetQueueAttributesRequest Uses

func (client *SQS) GetQueueAttributesRequest(*sqs.GetQueueAttributesInput) (*request.Request, *sqs.GetQueueAttributesOutput)

GetQueueAttributesRequest is not implemented. It will panic in all cases.

func (*SQS) GetQueueAttributesWithContext Uses

func (client *SQS) GetQueueAttributesWithContext(aws.Context, *sqs.GetQueueAttributesInput, ...request.Option) (*sqs.GetQueueAttributesOutput, error)

GetQueueAttributesWithContext is not implemented. It will panic in all cases.

func (*SQS) GetQueueUrl Uses

func (client *SQS) GetQueueUrl(*sqs.GetQueueUrlInput) (*sqs.GetQueueUrlOutput, error)

GetQueueUrl is not implemented. It will panic in all cases.

func (*SQS) GetQueueUrlRequest Uses

func (client *SQS) GetQueueUrlRequest(*sqs.GetQueueUrlInput) (*request.Request, *sqs.GetQueueUrlOutput)

GetQueueUrlRequest is not implemented. It will panic in all cases.

func (*SQS) GetQueueUrlWithContext Uses

func (client *SQS) GetQueueUrlWithContext(aws.Context, *sqs.GetQueueUrlInput, ...request.Option) (*sqs.GetQueueUrlOutput, error)

GetQueueUrlWithContext is not implemented. It will panic in all cases.

func (*SQS) ListDeadLetterSourceQueues Uses

func (client *SQS) ListDeadLetterSourceQueues(*sqs.ListDeadLetterSourceQueuesInput) (*sqs.ListDeadLetterSourceQueuesOutput, error)

ListDeadLetterSourceQueues is not implemented. It will panic in all cases.

func (*SQS) ListDeadLetterSourceQueuesRequest Uses

func (client *SQS) ListDeadLetterSourceQueuesRequest(*sqs.ListDeadLetterSourceQueuesInput) (*request.Request, *sqs.ListDeadLetterSourceQueuesOutput)

ListDeadLetterSourceQueuesRequest is not implemented. It will panic in all cases.

func (*SQS) ListDeadLetterSourceQueuesWithContext Uses

func (client *SQS) ListDeadLetterSourceQueuesWithContext(aws.Context, *sqs.ListDeadLetterSourceQueuesInput, ...request.Option) (*sqs.ListDeadLetterSourceQueuesOutput, error)

ListDeadLetterSourceQueuesWithContext is not implemented. It will panic in all cases.

func (*SQS) ListQueueTags Uses

func (client *SQS) ListQueueTags(*sqs.ListQueueTagsInput) (*sqs.ListQueueTagsOutput, error)

ListQueueTags is not implemented. It will panic in all cases.

func (*SQS) ListQueueTagsRequest Uses

func (client *SQS) ListQueueTagsRequest(*sqs.ListQueueTagsInput) (*request.Request, *sqs.ListQueueTagsOutput)

ListQueueTagsRequest is not implemented. It will panic in all cases.

func (*SQS) ListQueueTagsWithContext Uses

func (client *SQS) ListQueueTagsWithContext(aws.Context, *sqs.ListQueueTagsInput, ...request.Option) (*sqs.ListQueueTagsOutput, error)

ListQueueTagsWithContext is not implemented. It will panic in all cases.

func (*SQS) ListQueues Uses

func (client *SQS) ListQueues(input *sqs.ListQueuesInput) (*sqs.ListQueuesOutput, error)

ListQueues is fully supported.

func (*SQS) ListQueuesRequest Uses

func (client *SQS) ListQueuesRequest(*sqs.ListQueuesInput) (*request.Request, *sqs.ListQueuesOutput)

ListQueuesRequest is not implemented. It will panic in all cases.

func (*SQS) ListQueuesWithContext Uses

func (client *SQS) ListQueuesWithContext(aws.Context, *sqs.ListQueuesInput, ...request.Option) (*sqs.ListQueuesOutput, error)

ListQueuesWithContext is not implemented. It will panic in all cases.

func (*SQS) PurgeQueue Uses

func (client *SQS) PurgeQueue(*sqs.PurgeQueueInput) (*sqs.PurgeQueueOutput, error)

PurgeQueue is not implemented. It will panic in all cases.

func (*SQS) PurgeQueueRequest Uses

func (client *SQS) PurgeQueueRequest(*sqs.PurgeQueueInput) (*request.Request, *sqs.PurgeQueueOutput)

PurgeQueueRequest is not implemented. It will panic in all cases.

func (*SQS) PurgeQueueWithContext Uses

func (client *SQS) PurgeQueueWithContext(aws.Context, *sqs.PurgeQueueInput, ...request.Option) (*sqs.PurgeQueueOutput, error)

PurgeQueueWithContext is not implemented. It will panic in all cases.

func (*SQS) ReceiveMessage Uses

func (client *SQS) ReceiveMessage(input *sqs.ReceiveMessageInput) (*sqs.ReceiveMessageOutput, error)

ReceiveMessage is partially supported. The following are not supported:

- ReceiveMessageInput.AttributeNames

- ReceiveMessageInput.MessageAttributeNames

- ReceiveMessageInput.ReceiveRequestAttemptId

- ReceiveMessageInput.VisibilityTimeout

- ReceiveMessageInput.WaitTimeSeconds

func (*SQS) ReceiveMessageRequest Uses

func (client *SQS) ReceiveMessageRequest(*sqs.ReceiveMessageInput) (*request.Request, *sqs.ReceiveMessageOutput)

ReceiveMessageRequest is not implemented. It will panic in all cases.

func (*SQS) ReceiveMessageWithContext Uses

func (client *SQS) ReceiveMessageWithContext(aws.Context, *sqs.ReceiveMessageInput, ...request.Option) (*sqs.ReceiveMessageOutput, error)

ReceiveMessageWithContext is not implemented. It will panic in all cases.

func (*SQS) RemovePermission Uses

func (client *SQS) RemovePermission(*sqs.RemovePermissionInput) (*sqs.RemovePermissionOutput, error)

RemovePermission is not implemented. It will panic in all cases.

func (*SQS) RemovePermissionRequest Uses

func (client *SQS) RemovePermissionRequest(*sqs.RemovePermissionInput) (*request.Request, *sqs.RemovePermissionOutput)

RemovePermissionRequest is not implemented. It will panic in all cases.

func (*SQS) RemovePermissionWithContext Uses

func (client *SQS) RemovePermissionWithContext(aws.Context, *sqs.RemovePermissionInput, ...request.Option) (*sqs.RemovePermissionOutput, error)

RemovePermissionWithContext is not implemented. It will panic in all cases.

func (*SQS) SendMessage Uses

func (client *SQS) SendMessage(input *sqs.SendMessageInput) (*sqs.SendMessageOutput, error)

SendMessage is partially supported. The following are not supported:

- SendMessageInput.DelaySeconds

- SendMessageInput.MessageAttributes

- SendMessageInput.MessageDeduplicationId

- SendMessageInput.MessageGroupId

- SendMessageInput.MessageSystemAttributes

- SendMessageOutput.MD5OfMessageAttributes

- SendMessageOutput.MD5OfMessageBody

- SendMessageOutput.MD5OfMessageSystemAttributes

- SendMessageOutput.MessageId

- SendMessageOutput.SequenceNumber

func (*SQS) SendMessageBatch Uses

func (client *SQS) SendMessageBatch(*sqs.SendMessageBatchInput) (*sqs.SendMessageBatchOutput, error)

SendMessageBatch is not implemented. It will panic in all cases.

func (*SQS) SendMessageBatchRequest Uses

func (client *SQS) SendMessageBatchRequest(*sqs.SendMessageBatchInput) (*request.Request, *sqs.SendMessageBatchOutput)

SendMessageBatchRequest is not implemented. It will panic in all cases.

func (*SQS) SendMessageBatchWithContext Uses

func (client *SQS) SendMessageBatchWithContext(aws.Context, *sqs.SendMessageBatchInput, ...request.Option) (*sqs.SendMessageBatchOutput, error)

SendMessageBatchWithContext is not implemented. It will panic in all cases.

func (*SQS) SendMessageRequest Uses

func (client *SQS) SendMessageRequest(*sqs.SendMessageInput) (*request.Request, *sqs.SendMessageOutput)

SendMessageRequest is not implemented. It will panic in all cases.

func (*SQS) SendMessageWithContext Uses

func (client *SQS) SendMessageWithContext(aws.Context, *sqs.SendMessageInput, ...request.Option) (*sqs.SendMessageOutput, error)

SendMessageWithContext is not implemented. It will panic in all cases.

func (*SQS) SetQueueAttributes Uses

func (client *SQS) SetQueueAttributes(*sqs.SetQueueAttributesInput) (*sqs.SetQueueAttributesOutput, error)

SetQueueAttributes is not implemented. It will panic in all cases.

func (*SQS) SetQueueAttributesRequest Uses

func (client *SQS) SetQueueAttributesRequest(*sqs.SetQueueAttributesInput) (*request.Request, *sqs.SetQueueAttributesOutput)

SetQueueAttributesRequest is not implemented. It will panic in all cases.

func (*SQS) SetQueueAttributesWithContext Uses

func (client *SQS) SetQueueAttributesWithContext(aws.Context, *sqs.SetQueueAttributesInput, ...request.Option) (*sqs.SetQueueAttributesOutput, error)

SetQueueAttributesWithContext is not implemented. It will panic in all cases.

func (*SQS) TagQueue Uses

func (client *SQS) TagQueue(*sqs.TagQueueInput) (*sqs.TagQueueOutput, error)

TagQueue is not implemented. It will panic in all cases.

func (*SQS) TagQueueRequest Uses

func (client *SQS) TagQueueRequest(*sqs.TagQueueInput) (*request.Request, *sqs.TagQueueOutput)

TagQueueRequest is not implemented. It will panic in all cases.

func (*SQS) TagQueueWithContext Uses

func (client *SQS) TagQueueWithContext(aws.Context, *sqs.TagQueueInput, ...request.Option) (*sqs.TagQueueOutput, error)

TagQueueWithContext is not implemented. It will panic in all cases.

func (*SQS) UntagQueue Uses

func (client *SQS) UntagQueue(*sqs.UntagQueueInput) (*sqs.UntagQueueOutput, error)

UntagQueue is not implemented. It will panic in all cases.

func (*SQS) UntagQueueRequest Uses

func (client *SQS) UntagQueueRequest(*sqs.UntagQueueInput) (*request.Request, *sqs.UntagQueueOutput)

UntagQueueRequest is not implemented. It will panic in all cases.

func (*SQS) UntagQueueWithContext Uses

func (client *SQS) UntagQueueWithContext(aws.Context, *sqs.UntagQueueInput, ...request.Option) (*sqs.UntagQueueOutput, error)

UntagQueueWithContext is not implemented. It will panic in all cases.

Package mocksqs imports 11 packages (graph). Updated 2019-12-18. Refresh now. Tools for package owners.