testhelpers

package module
v0.0.0-...-55c57c2 Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2020 License: MIT Imports: 16 Imported by: 0

README

go-testhelpers

Series of functions for testing in go

AWS Helpers

These helpers are for mocking services provided by the AWS go SDK. While the SDK does describe how to mock the services it's very inconvenient to do so consistently

Dynamodb Helpers
mockedDbFunctions := make(map[string]interface{})
mockedDbFunctions["UpdateItem"] = testhelpers.UpdateItemFunc(func(input *dynamodb.UpdateItemInput) (*dynamodb.UpdateItemOutput, error) {

    key1 := input.Key["key1"]
    if *key1.S != "value1" {
        t.Errorf("Expected token to be 'value1', got '%s'", *key1.S)
    }
    return &dynamodb.UpdateItemOutput{}, nil
})
mockClient := testhelpers.NewMockDynamoDBClient(mockedDbFunctions)

Documentation

Overview

The MIT License (MIT)

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadHTTPRequestFixture

func LoadHTTPRequestFixture(data []byte) (*http.Request, error)

func LoadHTTPResponseFixture

func LoadHTTPResponseFixture(data []byte, req *http.Request) (*http.Response, error)

func NewBytesResponse

func NewBytesResponse(status int, body []byte) *http.Response

NewBytesResponse creates an *http.Response with a body based on the given bytes. Also accepts an http status code.

func NewClientRecorder

func NewClientRecorder(fileName string, verbose bool) *http.Client

This is meant to make it easy to record request and responses so that they can be used later as test fixtures

func NewJsonResponse

func NewJsonResponse(status int, body interface{}) (*http.Response, error)

NewJsonResponse creates an *http.Response with a body that is a json encoded representation of the given interface{}. Also accepts an http status code.

func NewMockDynamoDBClient

func NewMockDynamoDBClient(functions map[string]interface{}) dynamodbiface.DynamoDBAPI

NewMockDynamoDBClient creates a new mock dynamo db client example mockedDbFunctions := make(map[string]interface{})

mockedDbFunctions["UpdateItem"] = testhelpers.DynamoDBUpdateItem(func(input *dynamodb.UpdateItemInput) (*dynamodb.UpdateItemOutput, error) {
	return &dynamodb.UpdateItemOutput{}, nil
})mockedDbFunctions["Query"] = testhelpers.DynamoDBQuery(func(input *dynamodb.QueryInput) (*dynamodb.QueryOutput, error) {
	return &dynamodb.QueryOutput{}, nil
})

func NewRespBodyFromBytes

func NewRespBodyFromBytes(body []byte) io.ReadCloser

NewRespBodyFromBytes creates an io.ReadCloser from a byte slice that is suitable for use as an http response body.

func NewRespBodyFromString

func NewRespBodyFromString(body string) io.ReadCloser

NewRespBodyFromString creates an io.ReadCloser from a string that is suitable for use as an http response body.

func NewStringResponse

func NewStringResponse(status int, body string) *http.Response

NewStringResponse creates an *http.Response with a body based on the given string. Also accepts an http status code.

func NewTestClient

func NewTestClient(fn RoundTripFunc) *http.Client

NewTestClient returns *http.Client with Transport replaced to avoid making real calls

func NewXmlResponse

func NewXmlResponse(status int, body interface{}) (*http.Response, error)

NewXmlResponse creates an *http.Response with a body that is an xml encoded representation of the given interface{}. Also accepts an http status code.

Types

type DynamoDBBatchGetItem

type DynamoDBBatchGetItem func(input *dynamodb.BatchGetItemInput) (*dynamodb.BatchGetItemOutput, error)

type DynamoDBBatchGetItemPages

type DynamoDBBatchGetItemPages func(input *dynamodb.BatchGetItemInput, callback func(*dynamodb.BatchGetItemOutput, bool) bool) error

type DynamoDBBatchGetItemPagesWithContext

type DynamoDBBatchGetItemPagesWithContext func(context aws.Context, input *dynamodb.BatchGetItemInput, callback func(*dynamodb.BatchGetItemOutput, bool) bool, options ...request.Option) error

type DynamoDBBatchGetItemRequest

type DynamoDBBatchGetItemRequest func(input *dynamodb.BatchGetItemInput) (*request.Request, *dynamodb.BatchGetItemOutput)

type DynamoDBBatchGetItemWithContext

type DynamoDBBatchGetItemWithContext func(context aws.Context, input *dynamodb.BatchGetItemInput, options ...request.Option) (*dynamodb.BatchGetItemOutput, error)

type DynamoDBBatchWriteItem

type DynamoDBBatchWriteItem func(input *dynamodb.BatchWriteItemInput) (*dynamodb.BatchWriteItemOutput, error)

type DynamoDBBatchWriteItemRequest

type DynamoDBBatchWriteItemRequest func(input *dynamodb.BatchWriteItemInput) (*request.Request, *dynamodb.BatchWriteItemOutput)

type DynamoDBBatchWriteItemWithContext

type DynamoDBBatchWriteItemWithContext func(context aws.Context, input *dynamodb.BatchWriteItemInput, options ...request.Option) (*dynamodb.BatchWriteItemOutput, error)

type DynamoDBCreateBackup

type DynamoDBCreateBackup func(input *dynamodb.CreateBackupInput) (*dynamodb.CreateBackupOutput, error)

type DynamoDBCreateBackupRequest

type DynamoDBCreateBackupRequest func(input *dynamodb.CreateBackupInput) (*request.Request, *dynamodb.CreateBackupOutput)

type DynamoDBCreateBackupWithContext

type DynamoDBCreateBackupWithContext func(context aws.Context, input *dynamodb.CreateBackupInput, options ...request.Option) (*dynamodb.CreateBackupOutput, error)

type DynamoDBCreateGlobalTableWithContext

type DynamoDBCreateGlobalTableWithContext func(context aws.Context, input *dynamodb.CreateGlobalTableInput, options ...request.Option) (*dynamodb.CreateGlobalTableOutput, error)

type DynamoDBCreateTable

type DynamoDBCreateTable func(input *dynamodb.CreateTableInput) (*dynamodb.CreateTableOutput, error)

type DynamoDBCreateTableRequest

type DynamoDBCreateTableRequest func(input *dynamodb.CreateTableInput) (*request.Request, *dynamodb.CreateTableOutput)

type DynamoDBCreateTableWithContext

type DynamoDBCreateTableWithContext func(context aws.Context, input *dynamodb.CreateTableInput, options ...request.Option) (*dynamodb.CreateTableOutput, error)

type DynamoDBDeleteBackup

type DynamoDBDeleteBackup func(input *dynamodb.DeleteBackupInput) (*dynamodb.DeleteBackupOutput, error)

type DynamoDBDeleteBackupRequest

type DynamoDBDeleteBackupRequest func(input *dynamodb.DeleteBackupInput) (*request.Request, *dynamodb.DeleteBackupOutput)

type DynamoDBDeleteBackupWithContext

type DynamoDBDeleteBackupWithContext func(context aws.Context, input *dynamodb.DeleteBackupInput, options ...request.Option) (*dynamodb.DeleteBackupOutput, error)

type DynamoDBDeleteItem

type DynamoDBDeleteItem func(input *dynamodb.DeleteItemInput) (*dynamodb.DeleteItemOutput, error)

type DynamoDBDeleteItemRequest

type DynamoDBDeleteItemRequest func(input *dynamodb.DeleteItemInput) (*request.Request, *dynamodb.DeleteItemOutput)

type DynamoDBDeleteItemWithContext

type DynamoDBDeleteItemWithContext func(context aws.Context, input *dynamodb.DeleteItemInput, options ...request.Option) (*dynamodb.DeleteItemOutput, error)

type DynamoDBDeleteTable

type DynamoDBDeleteTable func(input *dynamodb.DeleteTableInput) (*dynamodb.DeleteTableOutput, error)

type DynamoDBDeleteTableRequest

type DynamoDBDeleteTableRequest func(input *dynamodb.DeleteTableInput) (*request.Request, *dynamodb.DeleteTableOutput)

type DynamoDBDeleteTableWithContext

type DynamoDBDeleteTableWithContext func(context aws.Context, input *dynamodb.DeleteTableInput, options ...request.Option) (*dynamodb.DeleteTableOutput, error)

type DynamoDBDescribeBackup

type DynamoDBDescribeBackup func(input *dynamodb.DescribeBackupInput) (*dynamodb.DescribeBackupOutput, error)

type DynamoDBDescribeBackupRequest

type DynamoDBDescribeBackupRequest func(input *dynamodb.DescribeBackupInput) (*request.Request, *dynamodb.DescribeBackupOutput)

type DynamoDBDescribeBackupWithContext

type DynamoDBDescribeBackupWithContext func(context aws.Context, input *dynamodb.DescribeBackupInput, options ...request.Option) (*dynamodb.DescribeBackupOutput, error)

type DynamoDBDescribeContinuousBackupsWithContext

type DynamoDBDescribeContinuousBackupsWithContext func(context aws.Context, input *dynamodb.DescribeContinuousBackupsInput, options ...request.Option) (*dynamodb.DescribeContinuousBackupsOutput, error)

type DynamoDBDescribeGlobalTableSettingsWithContext

type DynamoDBDescribeGlobalTableSettingsWithContext func(context aws.Context, input *dynamodb.DescribeGlobalTableSettingsInput, options ...request.Option) (*dynamodb.DescribeGlobalTableSettingsOutput, error)

type DynamoDBDescribeGlobalTableWithContext

type DynamoDBDescribeGlobalTableWithContext func(context aws.Context, input *dynamodb.DescribeGlobalTableInput, options ...request.Option) (*dynamodb.DescribeGlobalTableOutput, error)

type DynamoDBDescribeLimits

type DynamoDBDescribeLimits func(input *dynamodb.DescribeLimitsInput) (*dynamodb.DescribeLimitsOutput, error)

type DynamoDBDescribeLimitsRequest

type DynamoDBDescribeLimitsRequest func(input *dynamodb.DescribeLimitsInput) (*request.Request, *dynamodb.DescribeLimitsOutput)

type DynamoDBDescribeLimitsWithContext

type DynamoDBDescribeLimitsWithContext func(context aws.Context, input *dynamodb.DescribeLimitsInput, options ...request.Option) (*dynamodb.DescribeLimitsOutput, error)

type DynamoDBDescribeTable

type DynamoDBDescribeTable func(input *dynamodb.DescribeTableInput) (*dynamodb.DescribeTableOutput, error)

type DynamoDBDescribeTableRequest

type DynamoDBDescribeTableRequest func(input *dynamodb.DescribeTableInput) (*request.Request, *dynamodb.DescribeTableOutput)

type DynamoDBDescribeTableWithContext

type DynamoDBDescribeTableWithContext func(context aws.Context, input *dynamodb.DescribeTableInput, options ...request.Option) (*dynamodb.DescribeTableOutput, error)

type DynamoDBDescribeTimeToLiveWithContext

type DynamoDBDescribeTimeToLiveWithContext func(context aws.Context, input *dynamodb.DescribeTimeToLiveInput, options ...request.Option) (*dynamodb.DescribeTimeToLiveOutput, error)

type DynamoDBGetItem

type DynamoDBGetItem func(input *dynamodb.GetItemInput) (*dynamodb.GetItemOutput, error)

type DynamoDBGetItemRequest

type DynamoDBGetItemRequest func(input *dynamodb.GetItemInput) (*request.Request, *dynamodb.GetItemOutput)

type DynamoDBGetItemWithContext

type DynamoDBGetItemWithContext func(context aws.Context, input *dynamodb.GetItemInput, options ...request.Option) (*dynamodb.GetItemOutput, error)

type DynamoDBListBackups

type DynamoDBListBackups func(input *dynamodb.ListBackupsInput) (*dynamodb.ListBackupsOutput, error)

type DynamoDBListBackupsRequest

type DynamoDBListBackupsRequest func(input *dynamodb.ListBackupsInput) (*request.Request, *dynamodb.ListBackupsOutput)

type DynamoDBListBackupsWithContext

type DynamoDBListBackupsWithContext func(context aws.Context, input *dynamodb.ListBackupsInput, options ...request.Option) (*dynamodb.ListBackupsOutput, error)

type DynamoDBListGlobalTables

type DynamoDBListGlobalTables func(input *dynamodb.ListGlobalTablesInput) (*dynamodb.ListGlobalTablesOutput, error)

type DynamoDBListGlobalTablesWithContext

type DynamoDBListGlobalTablesWithContext func(context aws.Context, input *dynamodb.ListGlobalTablesInput, options ...request.Option) (*dynamodb.ListGlobalTablesOutput, error)

type DynamoDBListTables

type DynamoDBListTables func(input *dynamodb.ListTablesInput) (*dynamodb.ListTablesOutput, error)

type DynamoDBListTablesPages

type DynamoDBListTablesPages func(input *dynamodb.ListTablesInput, callback func(*dynamodb.ListTablesOutput, bool) bool) error

type DynamoDBListTablesPagesWithContext

type DynamoDBListTablesPagesWithContext func(context aws.Context, input *dynamodb.ListTablesInput, callback func(*dynamodb.ListTablesOutput, bool) bool, options ...request.Option) error

type DynamoDBListTablesRequest

type DynamoDBListTablesRequest func(input *dynamodb.ListTablesInput) (*request.Request, *dynamodb.ListTablesOutput)

type DynamoDBListTablesWithContext

type DynamoDBListTablesWithContext func(context aws.Context, input *dynamodb.ListTablesInput, options ...request.Option) (*dynamodb.ListTablesOutput, error)

type DynamoDBListTagsOfResourceWithContext

type DynamoDBListTagsOfResourceWithContext func(context aws.Context, input *dynamodb.ListTagsOfResourceInput, options ...request.Option) (*dynamodb.ListTagsOfResourceOutput, error)

type DynamoDBPutItem

type DynamoDBPutItem func(input *dynamodb.PutItemInput) (*dynamodb.PutItemOutput, error)

type DynamoDBPutItemRequest

type DynamoDBPutItemRequest func(input *dynamodb.PutItemInput) (*request.Request, *dynamodb.PutItemOutput)

type DynamoDBPutItemWithContext

type DynamoDBPutItemWithContext func(context aws.Context, input *dynamodb.PutItemInput, options ...request.Option) (*dynamodb.PutItemOutput, error)

type DynamoDBQuery

type DynamoDBQuery func(input *dynamodb.QueryInput) (*dynamodb.QueryOutput, error)

type DynamoDBQueryPages

type DynamoDBQueryPages func(input *dynamodb.QueryInput, callback func(*dynamodb.QueryOutput, bool) bool) error

type DynamoDBQueryPagesWithContext

type DynamoDBQueryPagesWithContext func(context aws.Context, input *dynamodb.QueryInput, callback func(*dynamodb.QueryOutput, bool) bool, options ...request.Option) error

type DynamoDBQueryRequest

type DynamoDBQueryRequest func(input *dynamodb.QueryInput) (*request.Request, *dynamodb.QueryOutput)

type DynamoDBQueryWithContext

type DynamoDBQueryWithContext func(context aws.Context, input *dynamodb.QueryInput, options ...request.Option) (*dynamodb.QueryOutput, error)

type DynamoDBRestoreTableFromBackupWithContext

type DynamoDBRestoreTableFromBackupWithContext func(context aws.Context, input *dynamodb.RestoreTableFromBackupInput, options ...request.Option) (*dynamodb.RestoreTableFromBackupOutput, error)

type DynamoDBRestoreTableToPointInTimeWithContext

type DynamoDBRestoreTableToPointInTimeWithContext func(context aws.Context, input *dynamodb.RestoreTableToPointInTimeInput, options ...request.Option) (*dynamodb.RestoreTableToPointInTimeOutput, error)

type DynamoDBScan

type DynamoDBScan func(input *dynamodb.ScanInput) (*dynamodb.ScanOutput, error)

type DynamoDBScanPages

type DynamoDBScanPages func(input *dynamodb.ScanInput, callback func(*dynamodb.ScanOutput, bool) bool) error

type DynamoDBScanPagesWithContext

type DynamoDBScanPagesWithContext func(context aws.Context, input *dynamodb.ScanInput, callback func(*dynamodb.ScanOutput, bool) bool, options ...request.Option) error

type DynamoDBScanRequest

type DynamoDBScanRequest func(input *dynamodb.ScanInput) (*request.Request, *dynamodb.ScanOutput)

type DynamoDBScanWithContext

type DynamoDBScanWithContext func(context aws.Context, input *dynamodb.ScanInput, options ...request.Option) (*dynamodb.ScanOutput, error)

type DynamoDBTagResource

type DynamoDBTagResource func(input *dynamodb.TagResourceInput) (*dynamodb.TagResourceOutput, error)

type DynamoDBTagResourceRequest

type DynamoDBTagResourceRequest func(input *dynamodb.TagResourceInput) (*request.Request, *dynamodb.TagResourceOutput)

type DynamoDBTagResourceWithContext

type DynamoDBTagResourceWithContext func(context aws.Context, input *dynamodb.TagResourceInput, options ...request.Option) (*dynamodb.TagResourceOutput, error)

type DynamoDBUntagResource

type DynamoDBUntagResource func(input *dynamodb.UntagResourceInput) (*dynamodb.UntagResourceOutput, error)

type DynamoDBUntagResourceRequest

type DynamoDBUntagResourceRequest func(input *dynamodb.UntagResourceInput) (*request.Request, *dynamodb.UntagResourceOutput)

type DynamoDBUntagResourceWithContext

type DynamoDBUntagResourceWithContext func(context aws.Context, input *dynamodb.UntagResourceInput, options ...request.Option) (*dynamodb.UntagResourceOutput, error)

type DynamoDBUpdateContinuousBackupsWithContext

type DynamoDBUpdateContinuousBackupsWithContext func(context aws.Context, input *dynamodb.UpdateContinuousBackupsInput, options ...request.Option) (*dynamodb.UpdateContinuousBackupsOutput, error)

type DynamoDBUpdateGlobalTableSettingsWithContext

type DynamoDBUpdateGlobalTableSettingsWithContext func(context aws.Context, input *dynamodb.UpdateGlobalTableSettingsInput, options ...request.Option) (*dynamodb.UpdateGlobalTableSettingsOutput, error)

type DynamoDBUpdateGlobalTableWithContext

type DynamoDBUpdateGlobalTableWithContext func(context aws.Context, input *dynamodb.UpdateGlobalTableInput, options ...request.Option) (*dynamodb.UpdateGlobalTableOutput, error)

type DynamoDBUpdateItem

type DynamoDBUpdateItem func(input *dynamodb.UpdateItemInput) (*dynamodb.UpdateItemOutput, error)

type DynamoDBUpdateItemRequest

type DynamoDBUpdateItemRequest func(input *dynamodb.UpdateItemInput) (*request.Request, *dynamodb.UpdateItemOutput)

type DynamoDBUpdateItemWithContext

type DynamoDBUpdateItemWithContext func(context aws.Context, input *dynamodb.UpdateItemInput, options ...request.Option) (*dynamodb.UpdateItemOutput, error)

type DynamoDBUpdateTable

type DynamoDBUpdateTable func(input *dynamodb.UpdateTableInput) (*dynamodb.UpdateTableOutput, error)

type DynamoDBUpdateTableRequest

type DynamoDBUpdateTableRequest func(input *dynamodb.UpdateTableInput) (*request.Request, *dynamodb.UpdateTableOutput)

type DynamoDBUpdateTableWithContext

type DynamoDBUpdateTableWithContext func(context aws.Context, input *dynamodb.UpdateTableInput, options ...request.Option) (*dynamodb.UpdateTableOutput, error)

type DynamoDBUpdateTimeToLive

type DynamoDBUpdateTimeToLive func(input *dynamodb.UpdateTimeToLiveInput) (*dynamodb.UpdateTimeToLiveOutput, error)

type DynamoDBUpdateTimeToLiveWithContext

type DynamoDBUpdateTimeToLiveWithContext func(context aws.Context, input *dynamodb.UpdateTimeToLiveInput, options ...request.Option) (*dynamodb.UpdateTimeToLiveOutput, error)

type DynamoDBWaitUntilTableExists

type DynamoDBWaitUntilTableExists func(input *dynamodb.DescribeTableInput) error

type DynamoDBWaitUntilTableExistsWithContext

type DynamoDBWaitUntilTableExistsWithContext func(context aws.Context, input *dynamodb.DescribeTableInput, options ...request.WaiterOption) error

type DynamoDBWaitUntilTableNotExists

type DynamoDBWaitUntilTableNotExists func(input *dynamodb.DescribeTableInput) error

type DynamoDBWaitUntilTableNotExistsWithContext

type DynamoDBWaitUntilTableNotExistsWithContext func(context aws.Context, input *dynamodb.DescribeTableInput, options ...request.WaiterOption) error

type MockDynamoDBClient

type MockDynamoDBClient struct {
	dynamodbiface.DynamoDBAPI
	// contains filtered or unexported fields
}

MockDynamoDBClient provides a mock implementation of DynamoDBAPI

To use this client you specify the function you would like to override by appending 'Func' to the original method name (e.g. DynamoDBUpdateItem)

// myFunc uses an SDK service client to make a request to
// Amazon DynamoDB.
func myFunc(svc dynamodbiface.DynamoDBAPI) bool {
    // Make svc.BatchGetItem request
}

func main() {
    sess := session.New()
    svc := dynamodb.New(sess)

    myFunc(svc)
}

In your _test.go file:

   func DynamoDBTestMy(t *testing.T) {
		//setup map of functions you would like to implement. Note the key is the aws sdk method name and the function type is the Me
		mockedDbFunctions := make(map[string]interface{})
		mockedDbFunctions["UpdateItem"] = testhelpers.DynamoDBUpdateItem(func(input *dynamodb.UpdateItemInput) (*dynamodb.UpdateItemOutput, error) {

			key := input.Key["key"]
			if *key.S != "value" {
				t.Errorf("Expected token to be 'value', got '%s'", *key.S)
			}
			return &dynamodb.UpdateItemOutput{}, nil
		})
		mockSvc := testhelpers.NewMockDynamoDBClient(mockedDbFunctions)'
		myfunc(mockSvc)

func (*MockDynamoDBClient) BatchGetItem

func (*MockDynamoDBClient) BatchGetItemPages

func (mdb *MockDynamoDBClient) BatchGetItemPages(input *dynamodb.BatchGetItemInput, callback func(*dynamodb.BatchGetItemOutput, bool) bool) error

func (*MockDynamoDBClient) BatchGetItemPagesWithContext

func (mdb *MockDynamoDBClient) BatchGetItemPagesWithContext(context aws.Context, input *dynamodb.BatchGetItemInput, callback func(*dynamodb.BatchGetItemOutput, bool) bool, options ...request.Option) error

func (*MockDynamoDBClient) BatchGetItemRequest

func (*MockDynamoDBClient) BatchGetItemWithContext

func (mdb *MockDynamoDBClient) BatchGetItemWithContext(context aws.Context, input *dynamodb.BatchGetItemInput, options ...request.Option) (*dynamodb.BatchGetItemOutput, error)

func (*MockDynamoDBClient) BatchWriteItem

func (*MockDynamoDBClient) BatchWriteItemRequest

func (*MockDynamoDBClient) BatchWriteItemWithContext

func (mdb *MockDynamoDBClient) BatchWriteItemWithContext(context aws.Context, input *dynamodb.BatchWriteItemInput, options ...request.Option) (*dynamodb.BatchWriteItemOutput, error)

func (*MockDynamoDBClient) CreateBackup

func (*MockDynamoDBClient) CreateBackupRequest

func (*MockDynamoDBClient) CreateBackupWithContext

func (mdb *MockDynamoDBClient) CreateBackupWithContext(context aws.Context, input *dynamodb.CreateBackupInput, options ...request.Option) (*dynamodb.CreateBackupOutput, error)

func (*MockDynamoDBClient) CreateGlobalTable

func (*MockDynamoDBClient) CreateGlobalTableRequest

func (*MockDynamoDBClient) CreateGlobalTableWithContext

func (mdb *MockDynamoDBClient) CreateGlobalTableWithContext(context aws.Context, input *dynamodb.CreateGlobalTableInput, options ...request.Option) (*dynamodb.CreateGlobalTableOutput, error)

func (*MockDynamoDBClient) CreateTable

func (*MockDynamoDBClient) CreateTableRequest

func (*MockDynamoDBClient) CreateTableWithContext

func (mdb *MockDynamoDBClient) CreateTableWithContext(context aws.Context, input *dynamodb.CreateTableInput, options ...request.Option) (*dynamodb.CreateTableOutput, error)

func (*MockDynamoDBClient) DeleteBackup

func (*MockDynamoDBClient) DeleteBackupRequest

func (*MockDynamoDBClient) DeleteBackupWithContext

func (mdb *MockDynamoDBClient) DeleteBackupWithContext(context aws.Context, input *dynamodb.DeleteBackupInput, options ...request.Option) (*dynamodb.DeleteBackupOutput, error)

func (*MockDynamoDBClient) DeleteItem

func (*MockDynamoDBClient) DeleteItemRequest

func (*MockDynamoDBClient) DeleteItemWithContext

func (mdb *MockDynamoDBClient) DeleteItemWithContext(context aws.Context, input *dynamodb.DeleteItemInput, options ...request.Option) (*dynamodb.DeleteItemOutput, error)

func (*MockDynamoDBClient) DeleteTable

func (*MockDynamoDBClient) DeleteTableRequest

func (*MockDynamoDBClient) DeleteTableWithContext

func (mdb *MockDynamoDBClient) DeleteTableWithContext(context aws.Context, input *dynamodb.DeleteTableInput, options ...request.Option) (*dynamodb.DeleteTableOutput, error)

func (*MockDynamoDBClient) DescribeBackup

func (*MockDynamoDBClient) DescribeBackupRequest

func (*MockDynamoDBClient) DescribeBackupWithContext

func (mdb *MockDynamoDBClient) DescribeBackupWithContext(context aws.Context, input *dynamodb.DescribeBackupInput, options ...request.Option) (*dynamodb.DescribeBackupOutput, error)

func (*MockDynamoDBClient) DescribeContinuousBackups

func (*MockDynamoDBClient) DescribeContinuousBackupsWithContext

func (mdb *MockDynamoDBClient) DescribeContinuousBackupsWithContext(context aws.Context, input *dynamodb.DescribeContinuousBackupsInput, options ...request.Option) (*dynamodb.DescribeContinuousBackupsOutput, error)

func (*MockDynamoDBClient) DescribeGlobalTable

func (*MockDynamoDBClient) DescribeGlobalTableRequest

func (*MockDynamoDBClient) DescribeGlobalTableSettingsWithContext

func (mdb *MockDynamoDBClient) DescribeGlobalTableSettingsWithContext(context aws.Context, input *dynamodb.DescribeGlobalTableSettingsInput, options ...request.Option) (*dynamodb.DescribeGlobalTableSettingsOutput, error)

func (*MockDynamoDBClient) DescribeGlobalTableWithContext

func (mdb *MockDynamoDBClient) DescribeGlobalTableWithContext(context aws.Context, input *dynamodb.DescribeGlobalTableInput, options ...request.Option) (*dynamodb.DescribeGlobalTableOutput, error)

func (*MockDynamoDBClient) DescribeLimits

func (*MockDynamoDBClient) DescribeLimitsRequest

func (*MockDynamoDBClient) DescribeLimitsWithContext

func (mdb *MockDynamoDBClient) DescribeLimitsWithContext(context aws.Context, input *dynamodb.DescribeLimitsInput, options ...request.Option) (*dynamodb.DescribeLimitsOutput, error)

func (*MockDynamoDBClient) DescribeTable

func (*MockDynamoDBClient) DescribeTableRequest

func (*MockDynamoDBClient) DescribeTableWithContext

func (mdb *MockDynamoDBClient) DescribeTableWithContext(context aws.Context, input *dynamodb.DescribeTableInput, options ...request.Option) (*dynamodb.DescribeTableOutput, error)

func (*MockDynamoDBClient) DescribeTimeToLive

func (*MockDynamoDBClient) DescribeTimeToLiveRequest

func (*MockDynamoDBClient) DescribeTimeToLiveWithContext

func (mdb *MockDynamoDBClient) DescribeTimeToLiveWithContext(context aws.Context, input *dynamodb.DescribeTimeToLiveInput, options ...request.Option) (*dynamodb.DescribeTimeToLiveOutput, error)

func (*MockDynamoDBClient) GetItem

func (*MockDynamoDBClient) GetItemRequest

func (*MockDynamoDBClient) GetItemWithContext

func (mdb *MockDynamoDBClient) GetItemWithContext(context aws.Context, input *dynamodb.GetItemInput, options ...request.Option) (*dynamodb.GetItemOutput, error)

func (*MockDynamoDBClient) ListBackups

func (*MockDynamoDBClient) ListBackupsRequest

func (*MockDynamoDBClient) ListBackupsWithContext

func (mdb *MockDynamoDBClient) ListBackupsWithContext(context aws.Context, input *dynamodb.ListBackupsInput, options ...request.Option) (*dynamodb.ListBackupsOutput, error)

func (*MockDynamoDBClient) ListGlobalTables

func (*MockDynamoDBClient) ListGlobalTablesRequest

func (*MockDynamoDBClient) ListGlobalTablesWithContext

func (mdb *MockDynamoDBClient) ListGlobalTablesWithContext(context aws.Context, input *dynamodb.ListGlobalTablesInput, options ...request.Option) (*dynamodb.ListGlobalTablesOutput, error)

func (*MockDynamoDBClient) ListTables

func (*MockDynamoDBClient) ListTablesPages

func (mdb *MockDynamoDBClient) ListTablesPages(input *dynamodb.ListTablesInput, callback func(*dynamodb.ListTablesOutput, bool) bool) error

func (*MockDynamoDBClient) ListTablesPagesWithContext

func (mdb *MockDynamoDBClient) ListTablesPagesWithContext(context aws.Context, input *dynamodb.ListTablesInput, callback func(*dynamodb.ListTablesOutput, bool) bool, options ...request.Option) error

func (*MockDynamoDBClient) ListTablesRequest

func (*MockDynamoDBClient) ListTablesWithContext

func (mdb *MockDynamoDBClient) ListTablesWithContext(context aws.Context, input *dynamodb.ListTablesInput, options ...request.Option) (*dynamodb.ListTablesOutput, error)

func (*MockDynamoDBClient) ListTagsOfResource

func (*MockDynamoDBClient) ListTagsOfResourceRequest

func (*MockDynamoDBClient) ListTagsOfResourceWithContext

func (mdb *MockDynamoDBClient) ListTagsOfResourceWithContext(context aws.Context, input *dynamodb.ListTagsOfResourceInput, options ...request.Option) (*dynamodb.ListTagsOfResourceOutput, error)

func (*MockDynamoDBClient) PutItem

func (*MockDynamoDBClient) PutItemRequest

func (*MockDynamoDBClient) PutItemWithContext

func (mdb *MockDynamoDBClient) PutItemWithContext(context aws.Context, input *dynamodb.PutItemInput, options ...request.Option) (*dynamodb.PutItemOutput, error)

func (*MockDynamoDBClient) Query

func (*MockDynamoDBClient) QueryPages

func (mdb *MockDynamoDBClient) QueryPages(input *dynamodb.QueryInput, callback func(*dynamodb.QueryOutput, bool) bool) error

func (*MockDynamoDBClient) QueryPagesWithContext

func (mdb *MockDynamoDBClient) QueryPagesWithContext(context aws.Context, input *dynamodb.QueryInput, callback func(*dynamodb.QueryOutput, bool) bool, options ...request.Option) error

func (*MockDynamoDBClient) QueryRequest

func (mdb *MockDynamoDBClient) QueryRequest(input *dynamodb.QueryInput) (*request.Request, *dynamodb.QueryOutput)

func (*MockDynamoDBClient) QueryWithContext

func (mdb *MockDynamoDBClient) QueryWithContext(context aws.Context, input *dynamodb.QueryInput, options ...request.Option) (*dynamodb.QueryOutput, error)

func (*MockDynamoDBClient) RestoreTableFromBackup

func (*MockDynamoDBClient) RestoreTableFromBackupRequest

func (*MockDynamoDBClient) RestoreTableFromBackupWithContext

func (mdb *MockDynamoDBClient) RestoreTableFromBackupWithContext(context aws.Context, input *dynamodb.RestoreTableFromBackupInput, options ...request.Option) (*dynamodb.RestoreTableFromBackupOutput, error)

func (*MockDynamoDBClient) RestoreTableToPointInTime

func (*MockDynamoDBClient) RestoreTableToPointInTimeWithContext

func (mdb *MockDynamoDBClient) RestoreTableToPointInTimeWithContext(context aws.Context, input *dynamodb.RestoreTableToPointInTimeInput, options ...request.Option) (*dynamodb.RestoreTableToPointInTimeOutput, error)

func (*MockDynamoDBClient) Scan

func (*MockDynamoDBClient) ScanPages

func (mdb *MockDynamoDBClient) ScanPages(input *dynamodb.ScanInput, callback func(*dynamodb.ScanOutput, bool) bool) error

func (*MockDynamoDBClient) ScanPagesWithContext

func (mdb *MockDynamoDBClient) ScanPagesWithContext(context aws.Context, input *dynamodb.ScanInput, callback func(*dynamodb.ScanOutput, bool) bool, options ...request.Option) error

func (*MockDynamoDBClient) ScanRequest

func (mdb *MockDynamoDBClient) ScanRequest(input *dynamodb.ScanInput) (*request.Request, *dynamodb.ScanOutput)

func (*MockDynamoDBClient) ScanWithContext

func (mdb *MockDynamoDBClient) ScanWithContext(context aws.Context, input *dynamodb.ScanInput, options ...request.Option) (*dynamodb.ScanOutput, error)

func (*MockDynamoDBClient) TagResource

func (*MockDynamoDBClient) TagResourceRequest

func (*MockDynamoDBClient) TagResourceWithContext

func (mdb *MockDynamoDBClient) TagResourceWithContext(context aws.Context, input *dynamodb.TagResourceInput, options ...request.Option) (*dynamodb.TagResourceOutput, error)

func (*MockDynamoDBClient) UntagResource

func (*MockDynamoDBClient) UntagResourceRequest

func (*MockDynamoDBClient) UntagResourceWithContext

func (mdb *MockDynamoDBClient) UntagResourceWithContext(context aws.Context, input *dynamodb.UntagResourceInput, options ...request.Option) (*dynamodb.UntagResourceOutput, error)

func (*MockDynamoDBClient) UpdateContinuousBackups

func (*MockDynamoDBClient) UpdateContinuousBackupsRequest

func (*MockDynamoDBClient) UpdateContinuousBackupsWithContext

func (mdb *MockDynamoDBClient) UpdateContinuousBackupsWithContext(context aws.Context, input *dynamodb.UpdateContinuousBackupsInput, options ...request.Option) (*dynamodb.UpdateContinuousBackupsOutput, error)

func (*MockDynamoDBClient) UpdateGlobalTable

func (*MockDynamoDBClient) UpdateGlobalTableRequest

func (*MockDynamoDBClient) UpdateGlobalTableSettings

func (*MockDynamoDBClient) UpdateGlobalTableSettingsWithContext

func (mdb *MockDynamoDBClient) UpdateGlobalTableSettingsWithContext(context aws.Context, input *dynamodb.UpdateGlobalTableSettingsInput, options ...request.Option) (*dynamodb.UpdateGlobalTableSettingsOutput, error)

func (*MockDynamoDBClient) UpdateGlobalTableWithContext

func (mdb *MockDynamoDBClient) UpdateGlobalTableWithContext(context aws.Context, input *dynamodb.UpdateGlobalTableInput, options ...request.Option) (*dynamodb.UpdateGlobalTableOutput, error)

func (*MockDynamoDBClient) UpdateItem

func (*MockDynamoDBClient) UpdateItemRequest

func (*MockDynamoDBClient) UpdateItemWithContext

func (mdb *MockDynamoDBClient) UpdateItemWithContext(context aws.Context, input *dynamodb.UpdateItemInput, options ...request.Option) (*dynamodb.UpdateItemOutput, error)

func (*MockDynamoDBClient) UpdateTable

func (*MockDynamoDBClient) UpdateTableRequest

func (*MockDynamoDBClient) UpdateTableWithContext

func (mdb *MockDynamoDBClient) UpdateTableWithContext(context aws.Context, input *dynamodb.UpdateTableInput, options ...request.Option) (*dynamodb.UpdateTableOutput, error)

func (*MockDynamoDBClient) UpdateTimeToLive

func (*MockDynamoDBClient) UpdateTimeToLiveRequest

func (*MockDynamoDBClient) UpdateTimeToLiveWithContext

func (mdb *MockDynamoDBClient) UpdateTimeToLiveWithContext(context aws.Context, input *dynamodb.UpdateTimeToLiveInput, options ...request.Option) (*dynamodb.UpdateTimeToLiveOutput, error)

func (*MockDynamoDBClient) WaitUntilTableExists

func (mdb *MockDynamoDBClient) WaitUntilTableExists(input *dynamodb.DescribeTableInput) error

func (*MockDynamoDBClient) WaitUntilTableExistsWithContext

func (mdb *MockDynamoDBClient) WaitUntilTableExistsWithContext(context aws.Context, input *dynamodb.DescribeTableInput, options ...request.WaiterOption) error

func (*MockDynamoDBClient) WaitUntilTableNotExists

func (mdb *MockDynamoDBClient) WaitUntilTableNotExists(input *dynamodb.DescribeTableInput) error

func (*MockDynamoDBClient) WaitUntilTableNotExistsWithContext

func (mdb *MockDynamoDBClient) WaitUntilTableNotExistsWithContext(context aws.Context, input *dynamodb.DescribeTableInput, options ...request.WaiterOption) error

type RoundTripFunc

type RoundTripFunc func(req *http.Request) *http.Response

RoundTripFunc .

func (RoundTripFunc) RoundTrip

func (f RoundTripFunc) RoundTrip(req *http.Request) (*http.Response, error)

RoundTrip .

Jump to

Keyboard shortcuts

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