Documentation ¶
Overview ¶
go:build mocks
go:build mocks
go:build mocks
go:build mocks
go:build mocks
Index ¶
- type TestCache
- func (c TestCache) Called(f any) (int, []any)
- func (c *TestCache) Get(key string) (string, error)
- func (c *TestCache) GetContext(ctx context.Context, key string) (string, error)
- func (c *TestCache) Len() int
- func (c *TestCache) LenContext(ctx context.Context) int
- func (c *TestCache) Set(key string, value string) error
- func (c *TestCache) SetContext(ctx context.Context, key string, value string) error
- type TestLogger
- func (c TestLogger) Called(f any) (int, []any)
- func (l *TestLogger) Error(msg string, args ...any)
- func (l *TestLogger) ErrorContext(ctx context.Context, msg string, args ...any)
- func (l *TestLogger) Info(msg string, args ...any)
- func (l *TestLogger) InfoContext(ctx context.Context, msg string, args ...any)
- func (l *TestLogger) Warn(msg string, args ...any)
- func (l *TestLogger) WarnContext(ctx context.Context, msg string, args ...any)
- type URLTestHash
- type URLTestRepo
- func (c URLTestRepo) Called(f any) (int, []any)
- func (r *URLTestRepo) Create(ctx context.Context, param *dtos.CreateHash) error
- func (r *URLTestRepo) Delete(ctx context.Context, hashOrFullURL string) error
- func (r *URLTestRepo) GetFullURL(ctx context.Context, hash string) (string, error)
- func (r *URLTestRepo) GetHash(ctx context.Context, fullURL string) (string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type TestCache ¶
type TestCache struct {
// contains filtered or unexported fields
}
func (*TestCache) GetContext ¶
type TestLogger ¶
type TestLogger struct {
// contains filtered or unexported fields
}
func NewTestLogger ¶
func NewTestLogger() *TestLogger
func (*TestLogger) Error ¶
func (l *TestLogger) Error(msg string, args ...any)
func (*TestLogger) ErrorContext ¶
func (l *TestLogger) ErrorContext(ctx context.Context, msg string, args ...any)
func (*TestLogger) Info ¶
func (l *TestLogger) Info(msg string, args ...any)
func (*TestLogger) InfoContext ¶
func (l *TestLogger) InfoContext(ctx context.Context, msg string, args ...any)
func (*TestLogger) Warn ¶
func (l *TestLogger) Warn(msg string, args ...any)
func (*TestLogger) WarnContext ¶
func (l *TestLogger) WarnContext(ctx context.Context, msg string, args ...any)
type URLTestHash ¶
type URLTestHash struct {
// contains filtered or unexported fields
}
func NewURLTestHash ¶
func NewURLTestHash(result string) *URLTestHash
func (*URLTestHash) Hash ¶
func (h *URLTestHash) Hash(val string) *dtos.HashGetter
type URLTestRepo ¶
type URLTestRepo struct {
// contains filtered or unexported fields
}
func NewUrlTestRepo ¶
func NewUrlTestRepo( item map[string]string, withError error, ) *URLTestRepo
func (*URLTestRepo) Create ¶
func (r *URLTestRepo) Create(ctx context.Context, param *dtos.CreateHash) error
func (*URLTestRepo) Delete ¶
func (r *URLTestRepo) Delete(ctx context.Context, hashOrFullURL string) error
func (*URLTestRepo) GetFullURL ¶
Click to show internal directories.
Click to hide internal directories.