Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ReadProfileNotFound = "4AC6E407-1D8E-4339-BA1C-862ACC58AC5E" ReadProfileFound = "20032259-738B-40A7-AAD7-306B69AF88D4" UpdateProfileNotFound = "E6096F2D-C706-42B6-B0E5-D7DD644ED079" UpdateProfile = "AC032259-738B-40A7-AAD7-306B69AAB909" )
Functions ¶
func NewTestDBA ¶
func NewTestDBA(r *MockRepository)
Types ¶
type Database ¶
type Database interface { GetItem(ctx context.Context, getItemInput *dynamodb.GetItemInput, optFns ...func(*dynamodb.Options)) (*dynamodb.GetItemOutput, error) PutItem(ctx context.Context, params *dynamodb.PutItemInput, optFns ...func(*dynamodb.Options)) (*dynamodb.PutItemOutput, error) }
type DynamoRepository ¶
Repository is the repository type
var Repo *DynamoRepository
Repo the repository used by dynamo
func NewRepo ¶
func NewRepo(a *config.AppConfig, cfg awsConfig.Config) *DynamoRepository
NewRepo creates a new repository
func (*DynamoRepository) ReadProfile ¶
func (m *DynamoRepository) ReadProfile(id string) (model.ProfileResponse, error)
func (*DynamoRepository) UpdateProfile ¶
func (m *DynamoRepository) UpdateProfile(id string, updateBody model.UpdateProfileRequest) (model.ProfileResponse, error)
type MockRepository ¶
var TestRepo *MockRepository
func (*MockRepository) ReadProfile ¶
func (m *MockRepository) ReadProfile(id string) (model.ProfileResponse, error)
func (*MockRepository) UpdateProfile ¶
func (m *MockRepository) UpdateProfile(id string, updateBody model.UpdateProfileRequest) (model.ProfileResponse, error)
type Repository ¶
type Repository interface { ReadProfile(id string) (model.ProfileResponse, error) UpdateProfile(id string, updateBody model.UpdateProfileRequest) (model.ProfileResponse, error) }
Click to show internal directories.
Click to hide internal directories.