Documentation
¶
Index ¶
- type MockManager
- func (_m *MockManager) Approve(ctx context.Context, id uint32, adminID uint32, qualityProfile string) (*ent.Request, error)
- func (_m *MockManager) Create(ctx context.Context, mediaType string, mediaID uint32, title string, ...) (*ent.Request, error)
- func (_m *MockManager) Deny(ctx context.Context, id uint32, adminID uint32, reason string) (*ent.Request, error)
- func (_m *MockManager) EXPECT() *MockManager_Expecter
- func (_m *MockManager) Get(ctx context.Context, id uint32) (*ent.Request, error)
- func (_m *MockManager) List(ctx context.Context, p db.ListRequestsParams) ([]*ent.Request, int, error)
- func (_m *MockManager) Reopen(ctx context.Context, id uint32) (*ent.Request, error)
- type MockManager_Approve_Call
- func (_c *MockManager_Approve_Call) Return(_a0 *ent.Request, _a1 error) *MockManager_Approve_Call
- func (_c *MockManager_Approve_Call) Run(...) *MockManager_Approve_Call
- func (_c *MockManager_Approve_Call) RunAndReturn(run func(context.Context, uint32, uint32, string) (*ent.Request, error)) *MockManager_Approve_Call
- type MockManager_Create_Call
- type MockManager_Deny_Call
- func (_c *MockManager_Deny_Call) Return(_a0 *ent.Request, _a1 error) *MockManager_Deny_Call
- func (_c *MockManager_Deny_Call) Run(run func(ctx context.Context, id uint32, adminID uint32, reason string)) *MockManager_Deny_Call
- func (_c *MockManager_Deny_Call) RunAndReturn(run func(context.Context, uint32, uint32, string) (*ent.Request, error)) *MockManager_Deny_Call
- type MockManager_Expecter
- func (_e *MockManager_Expecter) Approve(ctx interface{}, id interface{}, adminID interface{}, ...) *MockManager_Approve_Call
- func (_e *MockManager_Expecter) Create(ctx interface{}, mediaType interface{}, mediaID interface{}, title interface{}, ...) *MockManager_Create_Call
- func (_e *MockManager_Expecter) Deny(ctx interface{}, id interface{}, adminID interface{}, reason interface{}) *MockManager_Deny_Call
- func (_e *MockManager_Expecter) Get(ctx interface{}, id interface{}) *MockManager_Get_Call
- func (_e *MockManager_Expecter) List(ctx interface{}, p interface{}) *MockManager_List_Call
- func (_e *MockManager_Expecter) Reopen(ctx interface{}, id interface{}) *MockManager_Reopen_Call
- type MockManager_Get_Call
- func (_c *MockManager_Get_Call) Return(_a0 *ent.Request, _a1 error) *MockManager_Get_Call
- func (_c *MockManager_Get_Call) Run(run func(ctx context.Context, id uint32)) *MockManager_Get_Call
- func (_c *MockManager_Get_Call) RunAndReturn(run func(context.Context, uint32) (*ent.Request, error)) *MockManager_Get_Call
- type MockManager_List_Call
- func (_c *MockManager_List_Call) Return(_a0 []*ent.Request, _a1 int, _a2 error) *MockManager_List_Call
- func (_c *MockManager_List_Call) Run(run func(ctx context.Context, p db.ListRequestsParams)) *MockManager_List_Call
- func (_c *MockManager_List_Call) RunAndReturn(run func(context.Context, db.ListRequestsParams) ([]*ent.Request, int, error)) *MockManager_List_Call
- type MockManager_Reopen_Call
- func (_c *MockManager_Reopen_Call) Return(_a0 *ent.Request, _a1 error) *MockManager_Reopen_Call
- func (_c *MockManager_Reopen_Call) Run(run func(ctx context.Context, id uint32)) *MockManager_Reopen_Call
- func (_c *MockManager_Reopen_Call) RunAndReturn(run func(context.Context, uint32) (*ent.Request, error)) *MockManager_Reopen_Call
- type MockMovieAdder
- type MockMovieAdder_Add_Call
- func (_c *MockMovieAdder_Add_Call) Return(_a0 *ent.Movie, _a1 string, _a2 error) *MockMovieAdder_Add_Call
- func (_c *MockMovieAdder_Add_Call) Run(run func(ctx context.Context, tmdbID uint32, qualityProfile string)) *MockMovieAdder_Add_Call
- func (_c *MockMovieAdder_Add_Call) RunAndReturn(run func(context.Context, uint32, string) (*ent.Movie, string, error)) *MockMovieAdder_Add_Call
- type MockMovieAdder_Expecter
- type MockMovieAdder_GetByTMDBID_Call
- func (_c *MockMovieAdder_GetByTMDBID_Call) Return(_a0 *ent.Movie, _a1 error) *MockMovieAdder_GetByTMDBID_Call
- func (_c *MockMovieAdder_GetByTMDBID_Call) Run(run func(ctx context.Context, tmdbID uint32)) *MockMovieAdder_GetByTMDBID_Call
- func (_c *MockMovieAdder_GetByTMDBID_Call) RunAndReturn(run func(context.Context, uint32) (*ent.Movie, error)) *MockMovieAdder_GetByTMDBID_Call
- type MockShowAdder
- type MockShowAdder_Add_Call
- func (_c *MockShowAdder_Add_Call) Return(_a0 *ent.TVShow, _a1 error) *MockShowAdder_Add_Call
- func (_c *MockShowAdder_Add_Call) Run(run func(ctx context.Context, tvdbID uint32, qualityProfile string)) *MockShowAdder_Add_Call
- func (_c *MockShowAdder_Add_Call) RunAndReturn(run func(context.Context, uint32, string) (*ent.TVShow, error)) *MockShowAdder_Add_Call
- type MockShowAdder_Expecter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockManager ¶
MockManager is an autogenerated mock type for the Manager type
func NewMockManager ¶
func NewMockManager(t interface {
mock.TestingT
Cleanup(func())
}) *MockManager
NewMockManager creates a new instance of MockManager. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockManager) Approve ¶
func (_m *MockManager) Approve(ctx context.Context, id uint32, adminID uint32, qualityProfile string) (*ent.Request, error)
Approve provides a mock function with given fields: ctx, id, adminID, qualityProfile
func (*MockManager) Create ¶
func (_m *MockManager) Create(ctx context.Context, mediaType string, mediaID uint32, title string, requesterID uint32) (*ent.Request, error)
Create provides a mock function with given fields: ctx, mediaType, mediaID, title, requesterID
func (*MockManager) Deny ¶
func (_m *MockManager) Deny(ctx context.Context, id uint32, adminID uint32, reason string) (*ent.Request, error)
Deny provides a mock function with given fields: ctx, id, adminID, reason
func (*MockManager) EXPECT ¶
func (_m *MockManager) EXPECT() *MockManager_Expecter
type MockManager_Approve_Call ¶
MockManager_Approve_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Approve'
func (*MockManager_Approve_Call) Return ¶
func (_c *MockManager_Approve_Call) Return(_a0 *ent.Request, _a1 error) *MockManager_Approve_Call
func (*MockManager_Approve_Call) Run ¶
func (_c *MockManager_Approve_Call) Run(run func(ctx context.Context, id uint32, adminID uint32, qualityProfile string)) *MockManager_Approve_Call
func (*MockManager_Approve_Call) RunAndReturn ¶
func (_c *MockManager_Approve_Call) RunAndReturn(run func(context.Context, uint32, uint32, string) (*ent.Request, error)) *MockManager_Approve_Call
type MockManager_Create_Call ¶
MockManager_Create_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Create'
func (*MockManager_Create_Call) Return ¶
func (_c *MockManager_Create_Call) Return(_a0 *ent.Request, _a1 error) *MockManager_Create_Call
func (*MockManager_Create_Call) Run ¶
func (_c *MockManager_Create_Call) Run(run func(ctx context.Context, mediaType string, mediaID uint32, title string, requesterID uint32)) *MockManager_Create_Call
func (*MockManager_Create_Call) RunAndReturn ¶
type MockManager_Deny_Call ¶
MockManager_Deny_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Deny'
func (*MockManager_Deny_Call) Return ¶
func (_c *MockManager_Deny_Call) Return(_a0 *ent.Request, _a1 error) *MockManager_Deny_Call
func (*MockManager_Deny_Call) Run ¶
func (_c *MockManager_Deny_Call) Run(run func(ctx context.Context, id uint32, adminID uint32, reason string)) *MockManager_Deny_Call
func (*MockManager_Deny_Call) RunAndReturn ¶
func (_c *MockManager_Deny_Call) RunAndReturn(run func(context.Context, uint32, uint32, string) (*ent.Request, error)) *MockManager_Deny_Call
type MockManager_Expecter ¶
type MockManager_Expecter struct {
// contains filtered or unexported fields
}
func (*MockManager_Expecter) Approve ¶
func (_e *MockManager_Expecter) Approve(ctx interface{}, id interface{}, adminID interface{}, qualityProfile interface{}) *MockManager_Approve_Call
Approve is a helper method to define mock.On call
- ctx context.Context
- id uint32
- adminID uint32
- qualityProfile string
func (*MockManager_Expecter) Create ¶
func (_e *MockManager_Expecter) Create(ctx interface{}, mediaType interface{}, mediaID interface{}, title interface{}, requesterID interface{}) *MockManager_Create_Call
Create is a helper method to define mock.On call
- ctx context.Context
- mediaType string
- mediaID uint32
- title string
- requesterID uint32
func (*MockManager_Expecter) Deny ¶
func (_e *MockManager_Expecter) Deny(ctx interface{}, id interface{}, adminID interface{}, reason interface{}) *MockManager_Deny_Call
Deny is a helper method to define mock.On call
- ctx context.Context
- id uint32
- adminID uint32
- reason string
func (*MockManager_Expecter) Get ¶
func (_e *MockManager_Expecter) Get(ctx interface{}, id interface{}) *MockManager_Get_Call
Get is a helper method to define mock.On call
- ctx context.Context
- id uint32
func (*MockManager_Expecter) List ¶
func (_e *MockManager_Expecter) List(ctx interface{}, p interface{}) *MockManager_List_Call
List is a helper method to define mock.On call
- ctx context.Context
- p db.ListRequestsParams
func (*MockManager_Expecter) Reopen ¶
func (_e *MockManager_Expecter) Reopen(ctx interface{}, id interface{}) *MockManager_Reopen_Call
Reopen is a helper method to define mock.On call
- ctx context.Context
- id uint32
type MockManager_Get_Call ¶
MockManager_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'
func (*MockManager_Get_Call) Return ¶
func (_c *MockManager_Get_Call) Return(_a0 *ent.Request, _a1 error) *MockManager_Get_Call
func (*MockManager_Get_Call) Run ¶
func (_c *MockManager_Get_Call) Run(run func(ctx context.Context, id uint32)) *MockManager_Get_Call
func (*MockManager_Get_Call) RunAndReturn ¶
func (_c *MockManager_Get_Call) RunAndReturn(run func(context.Context, uint32) (*ent.Request, error)) *MockManager_Get_Call
type MockManager_List_Call ¶
MockManager_List_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'List'
func (*MockManager_List_Call) Return ¶
func (_c *MockManager_List_Call) Return(_a0 []*ent.Request, _a1 int, _a2 error) *MockManager_List_Call
func (*MockManager_List_Call) Run ¶
func (_c *MockManager_List_Call) Run(run func(ctx context.Context, p db.ListRequestsParams)) *MockManager_List_Call
func (*MockManager_List_Call) RunAndReturn ¶
func (_c *MockManager_List_Call) RunAndReturn(run func(context.Context, db.ListRequestsParams) ([]*ent.Request, int, error)) *MockManager_List_Call
type MockManager_Reopen_Call ¶
MockManager_Reopen_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Reopen'
func (*MockManager_Reopen_Call) Return ¶
func (_c *MockManager_Reopen_Call) Return(_a0 *ent.Request, _a1 error) *MockManager_Reopen_Call
func (*MockManager_Reopen_Call) Run ¶
func (_c *MockManager_Reopen_Call) Run(run func(ctx context.Context, id uint32)) *MockManager_Reopen_Call
func (*MockManager_Reopen_Call) RunAndReturn ¶
func (_c *MockManager_Reopen_Call) RunAndReturn(run func(context.Context, uint32) (*ent.Request, error)) *MockManager_Reopen_Call
type MockMovieAdder ¶
MockMovieAdder is an autogenerated mock type for the MovieAdder type
func NewMockMovieAdder ¶
func NewMockMovieAdder(t interface {
mock.TestingT
Cleanup(func())
}) *MockMovieAdder
NewMockMovieAdder creates a new instance of MockMovieAdder. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockMovieAdder) Add ¶
func (_m *MockMovieAdder) Add(ctx context.Context, tmdbID uint32, qualityProfile string) (*ent.Movie, string, error)
Add provides a mock function with given fields: ctx, tmdbID, qualityProfile
func (*MockMovieAdder) EXPECT ¶
func (_m *MockMovieAdder) EXPECT() *MockMovieAdder_Expecter
func (*MockMovieAdder) GetByTMDBID ¶
GetByTMDBID provides a mock function with given fields: ctx, tmdbID
type MockMovieAdder_Add_Call ¶
MockMovieAdder_Add_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Add'
func (*MockMovieAdder_Add_Call) Return ¶
func (_c *MockMovieAdder_Add_Call) Return(_a0 *ent.Movie, _a1 string, _a2 error) *MockMovieAdder_Add_Call
func (*MockMovieAdder_Add_Call) Run ¶
func (_c *MockMovieAdder_Add_Call) Run(run func(ctx context.Context, tmdbID uint32, qualityProfile string)) *MockMovieAdder_Add_Call
func (*MockMovieAdder_Add_Call) RunAndReturn ¶
func (_c *MockMovieAdder_Add_Call) RunAndReturn(run func(context.Context, uint32, string) (*ent.Movie, string, error)) *MockMovieAdder_Add_Call
type MockMovieAdder_Expecter ¶
type MockMovieAdder_Expecter struct {
// contains filtered or unexported fields
}
func (*MockMovieAdder_Expecter) Add ¶
func (_e *MockMovieAdder_Expecter) Add(ctx interface{}, tmdbID interface{}, qualityProfile interface{}) *MockMovieAdder_Add_Call
Add is a helper method to define mock.On call
- ctx context.Context
- tmdbID uint32
- qualityProfile string
func (*MockMovieAdder_Expecter) GetByTMDBID ¶
func (_e *MockMovieAdder_Expecter) GetByTMDBID(ctx interface{}, tmdbID interface{}) *MockMovieAdder_GetByTMDBID_Call
GetByTMDBID is a helper method to define mock.On call
- ctx context.Context
- tmdbID uint32
type MockMovieAdder_GetByTMDBID_Call ¶
MockMovieAdder_GetByTMDBID_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetByTMDBID'
func (*MockMovieAdder_GetByTMDBID_Call) Return ¶
func (_c *MockMovieAdder_GetByTMDBID_Call) Return(_a0 *ent.Movie, _a1 error) *MockMovieAdder_GetByTMDBID_Call
func (*MockMovieAdder_GetByTMDBID_Call) Run ¶
func (_c *MockMovieAdder_GetByTMDBID_Call) Run(run func(ctx context.Context, tmdbID uint32)) *MockMovieAdder_GetByTMDBID_Call
func (*MockMovieAdder_GetByTMDBID_Call) RunAndReturn ¶
func (_c *MockMovieAdder_GetByTMDBID_Call) RunAndReturn(run func(context.Context, uint32) (*ent.Movie, error)) *MockMovieAdder_GetByTMDBID_Call
type MockShowAdder ¶
MockShowAdder is an autogenerated mock type for the ShowAdder type
func NewMockShowAdder ¶
func NewMockShowAdder(t interface {
mock.TestingT
Cleanup(func())
}) *MockShowAdder
NewMockShowAdder creates a new instance of MockShowAdder. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*MockShowAdder) Add ¶
func (_m *MockShowAdder) Add(ctx context.Context, tvdbID uint32, qualityProfile string) (*ent.TVShow, error)
Add provides a mock function with given fields: ctx, tvdbID, qualityProfile
func (*MockShowAdder) EXPECT ¶
func (_m *MockShowAdder) EXPECT() *MockShowAdder_Expecter
type MockShowAdder_Add_Call ¶
MockShowAdder_Add_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Add'
func (*MockShowAdder_Add_Call) Return ¶
func (_c *MockShowAdder_Add_Call) Return(_a0 *ent.TVShow, _a1 error) *MockShowAdder_Add_Call
func (*MockShowAdder_Add_Call) Run ¶
func (_c *MockShowAdder_Add_Call) Run(run func(ctx context.Context, tvdbID uint32, qualityProfile string)) *MockShowAdder_Add_Call
func (*MockShowAdder_Add_Call) RunAndReturn ¶
func (_c *MockShowAdder_Add_Call) RunAndReturn(run func(context.Context, uint32, string) (*ent.TVShow, error)) *MockShowAdder_Add_Call
type MockShowAdder_Expecter ¶
type MockShowAdder_Expecter struct {
// contains filtered or unexported fields
}
func (*MockShowAdder_Expecter) Add ¶
func (_e *MockShowAdder_Expecter) Add(ctx interface{}, tvdbID interface{}, qualityProfile interface{}) *MockShowAdder_Add_Call
Add is a helper method to define mock.On call
- ctx context.Context
- tvdbID uint32
- qualityProfile string