Documentation ¶
Overview ¶
Package shorten is a generated GoMock package.
Index ¶
- Variables
- type MockShortener
- func (m *MockShortener) EXPECT() *MockShortenerMockRecorder
- func (m *MockShortener) Shorten(ctx context.Context, url *url.URL, ttl time.Duration) (*models.ShortenedURL, error)
- func (m *MockShortener) ShortenCustom(ctx context.Context, url *url.URL, customString string, ttl time.Duration) (*models.ShortenedURL, error)
- type MockShortenerMockRecorder
- type Shortener
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNotAvailable = errors.New("short url not available")
Functions ¶
This section is empty.
Types ¶
type MockShortener ¶
type MockShortener struct {
// contains filtered or unexported fields
}
MockShortener is a mock of Shortener interface.
func NewMockShortener ¶
func NewMockShortener(ctrl *gomock.Controller) *MockShortener
NewMockShortener creates a new mock instance.
func (*MockShortener) EXPECT ¶
func (m *MockShortener) EXPECT() *MockShortenerMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockShortener) Shorten ¶
func (m *MockShortener) Shorten(ctx context.Context, url *url.URL, ttl time.Duration) (*models.ShortenedURL, error)
Shorten mocks base method.
func (*MockShortener) ShortenCustom ¶
func (m *MockShortener) ShortenCustom(ctx context.Context, url *url.URL, customString string, ttl time.Duration) (*models.ShortenedURL, error)
ShortenCustom mocks base method.
type MockShortenerMockRecorder ¶
type MockShortenerMockRecorder struct {
// contains filtered or unexported fields
}
MockShortenerMockRecorder is the mock recorder for MockShortener.
func (*MockShortenerMockRecorder) Shorten ¶
func (mr *MockShortenerMockRecorder) Shorten(ctx, url, ttl interface{}) *gomock.Call
Shorten indicates an expected call of Shorten.
func (*MockShortenerMockRecorder) ShortenCustom ¶
func (mr *MockShortenerMockRecorder) ShortenCustom(ctx, url, customString, ttl interface{}) *gomock.Call
ShortenCustom indicates an expected call of ShortenCustom.
Click to show internal directories.
Click to hide internal directories.