Documentation
¶
Index ¶
- type MockAdopter
- type MockAdopter_AdoptManualTorrents_Call
- func (_c *MockAdopter_AdoptManualTorrents_Call) Return(_a0 []uint32, _a1 error) *MockAdopter_AdoptManualTorrents_Call
- func (_c *MockAdopter_AdoptManualTorrents_Call) Run(run func(ctx context.Context)) *MockAdopter_AdoptManualTorrents_Call
- func (_c *MockAdopter_AdoptManualTorrents_Call) RunAndReturn(run func(context.Context) ([]uint32, error)) *MockAdopter_AdoptManualTorrents_Call
- type MockAdopter_Expecter
- type MockChecker
- type MockChecker_CheckStatus_Call
- func (_c *MockChecker_CheckStatus_Call) Return(_a0 []download.CompletedDownload, _a1 error) *MockChecker_CheckStatus_Call
- func (_c *MockChecker_CheckStatus_Call) Run(run func(ctx context.Context)) *MockChecker_CheckStatus_Call
- func (_c *MockChecker_CheckStatus_Call) RunAndReturn(run func(context.Context) ([]download.CompletedDownload, error)) *MockChecker_CheckStatus_Call
- type MockChecker_Expecter
- type MockChecker_ReconcileEpisodeStatuses_Call
- func (_c *MockChecker_ReconcileEpisodeStatuses_Call) Return(_a0 error) *MockChecker_ReconcileEpisodeStatuses_Call
- func (_c *MockChecker_ReconcileEpisodeStatuses_Call) Run(run func(ctx context.Context)) *MockChecker_ReconcileEpisodeStatuses_Call
- func (_c *MockChecker_ReconcileEpisodeStatuses_Call) RunAndReturn(run func(context.Context) error) *MockChecker_ReconcileEpisodeStatuses_Call
- type MockCleaner
- type MockCleaner_Expecter
- type MockCleaner_PurgeOldRecords_Call
- func (_c *MockCleaner_PurgeOldRecords_Call) Return(_a0 error) *MockCleaner_PurgeOldRecords_Call
- func (_c *MockCleaner_PurgeOldRecords_Call) Run(run func(ctx context.Context)) *MockCleaner_PurgeOldRecords_Call
- func (_c *MockCleaner_PurgeOldRecords_Call) RunAndReturn(run func(context.Context) error) *MockCleaner_PurgeOldRecords_Call
- type MockCleaner_PurgeOrphanedTorrents_Call
- func (_c *MockCleaner_PurgeOrphanedTorrents_Call) Return(_a0 error) *MockCleaner_PurgeOrphanedTorrents_Call
- func (_c *MockCleaner_PurgeOrphanedTorrents_Call) Run(run func(ctx context.Context)) *MockCleaner_PurgeOrphanedTorrents_Call
- func (_c *MockCleaner_PurgeOrphanedTorrents_Call) RunAndReturn(run func(context.Context) error) *MockCleaner_PurgeOrphanedTorrents_Call
- type MockClient
- func (_m *MockClient) AddTorrent(ctx context.Context, src download.TorrentSource) (string, error)
- func (_m *MockClient) EXPECT() *MockClient_Expecter
- func (_m *MockClient) GetTorrent(ctx context.Context, hash string) (*download.Torrent, error)
- func (_m *MockClient) ListTorrents(ctx context.Context) ([]download.Torrent, error)
- func (_m *MockClient) PauseTorrent(ctx context.Context, hash string) error
- func (_m *MockClient) RemoveTorrent(ctx context.Context, hash string, deleteFiles bool) error
- func (_m *MockClient) ResumeTorrent(ctx context.Context, hash string) error
- func (_m *MockClient) TestConnection(ctx context.Context) error
- type MockClient_AddTorrent_Call
- func (_c *MockClient_AddTorrent_Call) Return(_a0 string, _a1 error) *MockClient_AddTorrent_Call
- func (_c *MockClient_AddTorrent_Call) Run(run func(ctx context.Context, src download.TorrentSource)) *MockClient_AddTorrent_Call
- func (_c *MockClient_AddTorrent_Call) RunAndReturn(run func(context.Context, download.TorrentSource) (string, error)) *MockClient_AddTorrent_Call
- type MockClient_Expecter
- func (_e *MockClient_Expecter) AddTorrent(ctx interface{}, src interface{}) *MockClient_AddTorrent_Call
- func (_e *MockClient_Expecter) GetTorrent(ctx interface{}, hash interface{}) *MockClient_GetTorrent_Call
- func (_e *MockClient_Expecter) ListTorrents(ctx interface{}) *MockClient_ListTorrents_Call
- func (_e *MockClient_Expecter) PauseTorrent(ctx interface{}, hash interface{}) *MockClient_PauseTorrent_Call
- func (_e *MockClient_Expecter) RemoveTorrent(ctx interface{}, hash interface{}, deleteFiles interface{}) *MockClient_RemoveTorrent_Call
- func (_e *MockClient_Expecter) ResumeTorrent(ctx interface{}, hash interface{}) *MockClient_ResumeTorrent_Call
- func (_e *MockClient_Expecter) TestConnection(ctx interface{}) *MockClient_TestConnection_Call
- type MockClient_GetTorrent_Call
- func (_c *MockClient_GetTorrent_Call) Return(_a0 *download.Torrent, _a1 error) *MockClient_GetTorrent_Call
- func (_c *MockClient_GetTorrent_Call) Run(run func(ctx context.Context, hash string)) *MockClient_GetTorrent_Call
- func (_c *MockClient_GetTorrent_Call) RunAndReturn(run func(context.Context, string) (*download.Torrent, error)) *MockClient_GetTorrent_Call
- type MockClient_ListTorrents_Call
- func (_c *MockClient_ListTorrents_Call) Return(_a0 []download.Torrent, _a1 error) *MockClient_ListTorrents_Call
- func (_c *MockClient_ListTorrents_Call) Run(run func(ctx context.Context)) *MockClient_ListTorrents_Call
- func (_c *MockClient_ListTorrents_Call) RunAndReturn(run func(context.Context) ([]download.Torrent, error)) *MockClient_ListTorrents_Call
- type MockClient_PauseTorrent_Call
- func (_c *MockClient_PauseTorrent_Call) Return(_a0 error) *MockClient_PauseTorrent_Call
- func (_c *MockClient_PauseTorrent_Call) Run(run func(ctx context.Context, hash string)) *MockClient_PauseTorrent_Call
- func (_c *MockClient_PauseTorrent_Call) RunAndReturn(run func(context.Context, string) error) *MockClient_PauseTorrent_Call
- type MockClient_RemoveTorrent_Call
- func (_c *MockClient_RemoveTorrent_Call) Return(_a0 error) *MockClient_RemoveTorrent_Call
- func (_c *MockClient_RemoveTorrent_Call) Run(run func(ctx context.Context, hash string, deleteFiles bool)) *MockClient_RemoveTorrent_Call
- func (_c *MockClient_RemoveTorrent_Call) RunAndReturn(run func(context.Context, string, bool) error) *MockClient_RemoveTorrent_Call
- type MockClient_ResumeTorrent_Call
- func (_c *MockClient_ResumeTorrent_Call) Return(_a0 error) *MockClient_ResumeTorrent_Call
- func (_c *MockClient_ResumeTorrent_Call) Run(run func(ctx context.Context, hash string)) *MockClient_ResumeTorrent_Call
- func (_c *MockClient_ResumeTorrent_Call) RunAndReturn(run func(context.Context, string) error) *MockClient_ResumeTorrent_Call
- type MockClient_TestConnection_Call
- func (_c *MockClient_TestConnection_Call) Return(_a0 error) *MockClient_TestConnection_Call
- func (_c *MockClient_TestConnection_Call) Run(run func(ctx context.Context)) *MockClient_TestConnection_Call
- func (_c *MockClient_TestConnection_Call) RunAndReturn(run func(context.Context) error) *MockClient_TestConnection_Call
- type MockDownloader
- func (_m *MockDownloader) CancelQueueItem(ctx context.Context, recordID uint32) error
- func (_m *MockDownloader) CheckStatus(ctx context.Context) ([]download.CompletedDownload, error)
- func (_m *MockDownloader) EXPECT() *MockDownloader_Expecter
- func (_m *MockDownloader) Grab(ctx context.Context, result indexer.SearchResult, movieID uint32) (*ent.DownloadRecord, error)
- func (_m *MockDownloader) GrabEpisode(ctx context.Context, result indexer.SearchResult, episodeID uint32) (*ent.DownloadRecord, error)
- func (_m *MockDownloader) PauseQueueItem(ctx context.Context, recordID uint32) error
- func (_m *MockDownloader) Queue(ctx context.Context) (download.QueueSnapshot, error)
- func (_m *MockDownloader) ReconcileEpisodeStatuses(ctx context.Context) error
- func (_m *MockDownloader) RemoveTorrent(ctx context.Context, downloadClientName string, torrentHash string) error
- func (_m *MockDownloader) ResumeQueueItem(ctx context.Context, recordID uint32) error
- func (_m *MockDownloader) Test(ctx context.Context, p download.TestParams) error
- func (_m *MockDownloader) TestByName(ctx context.Context, name string) error
- type MockDownloader_CancelQueueItem_Call
- func (_c *MockDownloader_CancelQueueItem_Call) Return(_a0 error) *MockDownloader_CancelQueueItem_Call
- func (_c *MockDownloader_CancelQueueItem_Call) Run(run func(ctx context.Context, recordID uint32)) *MockDownloader_CancelQueueItem_Call
- func (_c *MockDownloader_CancelQueueItem_Call) RunAndReturn(run func(context.Context, uint32) error) *MockDownloader_CancelQueueItem_Call
- type MockDownloader_CheckStatus_Call
- func (_c *MockDownloader_CheckStatus_Call) Return(_a0 []download.CompletedDownload, _a1 error) *MockDownloader_CheckStatus_Call
- func (_c *MockDownloader_CheckStatus_Call) Run(run func(ctx context.Context)) *MockDownloader_CheckStatus_Call
- func (_c *MockDownloader_CheckStatus_Call) RunAndReturn(run func(context.Context) ([]download.CompletedDownload, error)) *MockDownloader_CheckStatus_Call
- type MockDownloader_Expecter
- func (_e *MockDownloader_Expecter) CancelQueueItem(ctx interface{}, recordID interface{}) *MockDownloader_CancelQueueItem_Call
- func (_e *MockDownloader_Expecter) CheckStatus(ctx interface{}) *MockDownloader_CheckStatus_Call
- func (_e *MockDownloader_Expecter) Grab(ctx interface{}, result interface{}, movieID interface{}) *MockDownloader_Grab_Call
- func (_e *MockDownloader_Expecter) GrabEpisode(ctx interface{}, result interface{}, episodeID interface{}) *MockDownloader_GrabEpisode_Call
- func (_e *MockDownloader_Expecter) PauseQueueItem(ctx interface{}, recordID interface{}) *MockDownloader_PauseQueueItem_Call
- func (_e *MockDownloader_Expecter) Queue(ctx interface{}) *MockDownloader_Queue_Call
- func (_e *MockDownloader_Expecter) ReconcileEpisodeStatuses(ctx interface{}) *MockDownloader_ReconcileEpisodeStatuses_Call
- func (_e *MockDownloader_Expecter) RemoveTorrent(ctx interface{}, downloadClientName interface{}, torrentHash interface{}) *MockDownloader_RemoveTorrent_Call
- func (_e *MockDownloader_Expecter) ResumeQueueItem(ctx interface{}, recordID interface{}) *MockDownloader_ResumeQueueItem_Call
- func (_e *MockDownloader_Expecter) Test(ctx interface{}, p interface{}) *MockDownloader_Test_Call
- func (_e *MockDownloader_Expecter) TestByName(ctx interface{}, name interface{}) *MockDownloader_TestByName_Call
- type MockDownloader_GrabEpisode_Call
- func (_c *MockDownloader_GrabEpisode_Call) Return(_a0 *ent.DownloadRecord, _a1 error) *MockDownloader_GrabEpisode_Call
- func (_c *MockDownloader_GrabEpisode_Call) Run(run func(ctx context.Context, result indexer.SearchResult, episodeID uint32)) *MockDownloader_GrabEpisode_Call
- func (_c *MockDownloader_GrabEpisode_Call) RunAndReturn(...) *MockDownloader_GrabEpisode_Call
- type MockDownloader_Grab_Call
- func (_c *MockDownloader_Grab_Call) Return(_a0 *ent.DownloadRecord, _a1 error) *MockDownloader_Grab_Call
- func (_c *MockDownloader_Grab_Call) Run(run func(ctx context.Context, result indexer.SearchResult, movieID uint32)) *MockDownloader_Grab_Call
- func (_c *MockDownloader_Grab_Call) RunAndReturn(...) *MockDownloader_Grab_Call
- type MockDownloader_PauseQueueItem_Call
- func (_c *MockDownloader_PauseQueueItem_Call) Return(_a0 error) *MockDownloader_PauseQueueItem_Call
- func (_c *MockDownloader_PauseQueueItem_Call) Run(run func(ctx context.Context, recordID uint32)) *MockDownloader_PauseQueueItem_Call
- func (_c *MockDownloader_PauseQueueItem_Call) RunAndReturn(run func(context.Context, uint32) error) *MockDownloader_PauseQueueItem_Call
- type MockDownloader_Queue_Call
- func (_c *MockDownloader_Queue_Call) Return(_a0 download.QueueSnapshot, _a1 error) *MockDownloader_Queue_Call
- func (_c *MockDownloader_Queue_Call) Run(run func(ctx context.Context)) *MockDownloader_Queue_Call
- func (_c *MockDownloader_Queue_Call) RunAndReturn(run func(context.Context) (download.QueueSnapshot, error)) *MockDownloader_Queue_Call
- type MockDownloader_ReconcileEpisodeStatuses_Call
- func (_c *MockDownloader_ReconcileEpisodeStatuses_Call) Return(_a0 error) *MockDownloader_ReconcileEpisodeStatuses_Call
- func (_c *MockDownloader_ReconcileEpisodeStatuses_Call) Run(run func(ctx context.Context)) *MockDownloader_ReconcileEpisodeStatuses_Call
- func (_c *MockDownloader_ReconcileEpisodeStatuses_Call) RunAndReturn(run func(context.Context) error) *MockDownloader_ReconcileEpisodeStatuses_Call
- type MockDownloader_RemoveTorrent_Call
- func (_c *MockDownloader_RemoveTorrent_Call) Return(_a0 error) *MockDownloader_RemoveTorrent_Call
- func (_c *MockDownloader_RemoveTorrent_Call) Run(run func(ctx context.Context, downloadClientName string, torrentHash string)) *MockDownloader_RemoveTorrent_Call
- func (_c *MockDownloader_RemoveTorrent_Call) RunAndReturn(run func(context.Context, string, string) error) *MockDownloader_RemoveTorrent_Call
- type MockDownloader_ResumeQueueItem_Call
- func (_c *MockDownloader_ResumeQueueItem_Call) Return(_a0 error) *MockDownloader_ResumeQueueItem_Call
- func (_c *MockDownloader_ResumeQueueItem_Call) Run(run func(ctx context.Context, recordID uint32)) *MockDownloader_ResumeQueueItem_Call
- func (_c *MockDownloader_ResumeQueueItem_Call) RunAndReturn(run func(context.Context, uint32) error) *MockDownloader_ResumeQueueItem_Call
- type MockDownloader_TestByName_Call
- func (_c *MockDownloader_TestByName_Call) Return(_a0 error) *MockDownloader_TestByName_Call
- func (_c *MockDownloader_TestByName_Call) Run(run func(ctx context.Context, name string)) *MockDownloader_TestByName_Call
- func (_c *MockDownloader_TestByName_Call) RunAndReturn(run func(context.Context, string) error) *MockDownloader_TestByName_Call
- type MockDownloader_Test_Call
- func (_c *MockDownloader_Test_Call) Return(_a0 error) *MockDownloader_Test_Call
- func (_c *MockDownloader_Test_Call) Run(run func(ctx context.Context, p download.TestParams)) *MockDownloader_Test_Call
- func (_c *MockDownloader_Test_Call) RunAndReturn(run func(context.Context, download.TestParams) error) *MockDownloader_Test_Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockAdopter ¶
MockAdopter is an autogenerated mock type for the Adopter type
func NewMockAdopter ¶
func NewMockAdopter(t interface {
mock.TestingT
Cleanup(func())
}) *MockAdopter
NewMockAdopter creates a new instance of MockAdopter. 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 (*MockAdopter) AdoptManualTorrents ¶
func (_m *MockAdopter) AdoptManualTorrents(ctx context.Context) ([]uint32, error)
AdoptManualTorrents provides a mock function with given fields: ctx
func (*MockAdopter) EXPECT ¶
func (_m *MockAdopter) EXPECT() *MockAdopter_Expecter
type MockAdopter_AdoptManualTorrents_Call ¶
MockAdopter_AdoptManualTorrents_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'AdoptManualTorrents'
func (*MockAdopter_AdoptManualTorrents_Call) Return ¶
func (_c *MockAdopter_AdoptManualTorrents_Call) Return(_a0 []uint32, _a1 error) *MockAdopter_AdoptManualTorrents_Call
func (*MockAdopter_AdoptManualTorrents_Call) Run ¶
func (_c *MockAdopter_AdoptManualTorrents_Call) Run(run func(ctx context.Context)) *MockAdopter_AdoptManualTorrents_Call
func (*MockAdopter_AdoptManualTorrents_Call) RunAndReturn ¶
func (_c *MockAdopter_AdoptManualTorrents_Call) RunAndReturn(run func(context.Context) ([]uint32, error)) *MockAdopter_AdoptManualTorrents_Call
type MockAdopter_Expecter ¶
type MockAdopter_Expecter struct {
// contains filtered or unexported fields
}
func (*MockAdopter_Expecter) AdoptManualTorrents ¶
func (_e *MockAdopter_Expecter) AdoptManualTorrents(ctx interface{}) *MockAdopter_AdoptManualTorrents_Call
AdoptManualTorrents is a helper method to define mock.On call
- ctx context.Context
type MockChecker ¶
MockChecker is an autogenerated mock type for the Checker type
func NewMockChecker ¶
func NewMockChecker(t interface {
mock.TestingT
Cleanup(func())
}) *MockChecker
NewMockChecker creates a new instance of MockChecker. 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 (*MockChecker) CheckStatus ¶
func (_m *MockChecker) CheckStatus(ctx context.Context) ([]download.CompletedDownload, error)
CheckStatus provides a mock function with given fields: ctx
func (*MockChecker) EXPECT ¶
func (_m *MockChecker) EXPECT() *MockChecker_Expecter
func (*MockChecker) ReconcileEpisodeStatuses ¶
func (_m *MockChecker) ReconcileEpisodeStatuses(ctx context.Context) error
ReconcileEpisodeStatuses provides a mock function with given fields: ctx
type MockChecker_CheckStatus_Call ¶
MockChecker_CheckStatus_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CheckStatus'
func (*MockChecker_CheckStatus_Call) Return ¶
func (_c *MockChecker_CheckStatus_Call) Return(_a0 []download.CompletedDownload, _a1 error) *MockChecker_CheckStatus_Call
func (*MockChecker_CheckStatus_Call) Run ¶
func (_c *MockChecker_CheckStatus_Call) Run(run func(ctx context.Context)) *MockChecker_CheckStatus_Call
func (*MockChecker_CheckStatus_Call) RunAndReturn ¶
func (_c *MockChecker_CheckStatus_Call) RunAndReturn(run func(context.Context) ([]download.CompletedDownload, error)) *MockChecker_CheckStatus_Call
type MockChecker_Expecter ¶
type MockChecker_Expecter struct {
// contains filtered or unexported fields
}
func (*MockChecker_Expecter) CheckStatus ¶
func (_e *MockChecker_Expecter) CheckStatus(ctx interface{}) *MockChecker_CheckStatus_Call
CheckStatus is a helper method to define mock.On call
- ctx context.Context
func (*MockChecker_Expecter) ReconcileEpisodeStatuses ¶
func (_e *MockChecker_Expecter) ReconcileEpisodeStatuses(ctx interface{}) *MockChecker_ReconcileEpisodeStatuses_Call
ReconcileEpisodeStatuses is a helper method to define mock.On call
- ctx context.Context
type MockChecker_ReconcileEpisodeStatuses_Call ¶
MockChecker_ReconcileEpisodeStatuses_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ReconcileEpisodeStatuses'
func (*MockChecker_ReconcileEpisodeStatuses_Call) Return ¶
func (_c *MockChecker_ReconcileEpisodeStatuses_Call) Return(_a0 error) *MockChecker_ReconcileEpisodeStatuses_Call
func (*MockChecker_ReconcileEpisodeStatuses_Call) Run ¶
func (_c *MockChecker_ReconcileEpisodeStatuses_Call) Run(run func(ctx context.Context)) *MockChecker_ReconcileEpisodeStatuses_Call
func (*MockChecker_ReconcileEpisodeStatuses_Call) RunAndReturn ¶
func (_c *MockChecker_ReconcileEpisodeStatuses_Call) RunAndReturn(run func(context.Context) error) *MockChecker_ReconcileEpisodeStatuses_Call
type MockCleaner ¶
MockCleaner is an autogenerated mock type for the Cleaner type
func NewMockCleaner ¶
func NewMockCleaner(t interface {
mock.TestingT
Cleanup(func())
}) *MockCleaner
NewMockCleaner creates a new instance of MockCleaner. 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 (*MockCleaner) EXPECT ¶
func (_m *MockCleaner) EXPECT() *MockCleaner_Expecter
func (*MockCleaner) PurgeOldRecords ¶
func (_m *MockCleaner) PurgeOldRecords(ctx context.Context) error
PurgeOldRecords provides a mock function with given fields: ctx
func (*MockCleaner) PurgeOrphanedTorrents ¶
func (_m *MockCleaner) PurgeOrphanedTorrents(ctx context.Context) error
PurgeOrphanedTorrents provides a mock function with given fields: ctx
type MockCleaner_Expecter ¶
type MockCleaner_Expecter struct {
// contains filtered or unexported fields
}
func (*MockCleaner_Expecter) PurgeOldRecords ¶
func (_e *MockCleaner_Expecter) PurgeOldRecords(ctx interface{}) *MockCleaner_PurgeOldRecords_Call
PurgeOldRecords is a helper method to define mock.On call
- ctx context.Context
func (*MockCleaner_Expecter) PurgeOrphanedTorrents ¶
func (_e *MockCleaner_Expecter) PurgeOrphanedTorrents(ctx interface{}) *MockCleaner_PurgeOrphanedTorrents_Call
PurgeOrphanedTorrents is a helper method to define mock.On call
- ctx context.Context
type MockCleaner_PurgeOldRecords_Call ¶
MockCleaner_PurgeOldRecords_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'PurgeOldRecords'
func (*MockCleaner_PurgeOldRecords_Call) Return ¶
func (_c *MockCleaner_PurgeOldRecords_Call) Return(_a0 error) *MockCleaner_PurgeOldRecords_Call
func (*MockCleaner_PurgeOldRecords_Call) Run ¶
func (_c *MockCleaner_PurgeOldRecords_Call) Run(run func(ctx context.Context)) *MockCleaner_PurgeOldRecords_Call
func (*MockCleaner_PurgeOldRecords_Call) RunAndReturn ¶
func (_c *MockCleaner_PurgeOldRecords_Call) RunAndReturn(run func(context.Context) error) *MockCleaner_PurgeOldRecords_Call
type MockCleaner_PurgeOrphanedTorrents_Call ¶
MockCleaner_PurgeOrphanedTorrents_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'PurgeOrphanedTorrents'
func (*MockCleaner_PurgeOrphanedTorrents_Call) Return ¶
func (_c *MockCleaner_PurgeOrphanedTorrents_Call) Return(_a0 error) *MockCleaner_PurgeOrphanedTorrents_Call
func (*MockCleaner_PurgeOrphanedTorrents_Call) Run ¶
func (_c *MockCleaner_PurgeOrphanedTorrents_Call) Run(run func(ctx context.Context)) *MockCleaner_PurgeOrphanedTorrents_Call
func (*MockCleaner_PurgeOrphanedTorrents_Call) RunAndReturn ¶
func (_c *MockCleaner_PurgeOrphanedTorrents_Call) RunAndReturn(run func(context.Context) error) *MockCleaner_PurgeOrphanedTorrents_Call
type MockClient ¶
MockClient is an autogenerated mock type for the Client type
func NewMockClient ¶
func NewMockClient(t interface {
mock.TestingT
Cleanup(func())
}) *MockClient
NewMockClient creates a new instance of MockClient. 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 (*MockClient) AddTorrent ¶
func (_m *MockClient) AddTorrent(ctx context.Context, src download.TorrentSource) (string, error)
AddTorrent provides a mock function with given fields: ctx, src
func (*MockClient) EXPECT ¶
func (_m *MockClient) EXPECT() *MockClient_Expecter
func (*MockClient) GetTorrent ¶
GetTorrent provides a mock function with given fields: ctx, hash
func (*MockClient) ListTorrents ¶
ListTorrents provides a mock function with given fields: ctx
func (*MockClient) PauseTorrent ¶
func (_m *MockClient) PauseTorrent(ctx context.Context, hash string) error
PauseTorrent provides a mock function with given fields: ctx, hash
func (*MockClient) RemoveTorrent ¶
RemoveTorrent provides a mock function with given fields: ctx, hash, deleteFiles
func (*MockClient) ResumeTorrent ¶
func (_m *MockClient) ResumeTorrent(ctx context.Context, hash string) error
ResumeTorrent provides a mock function with given fields: ctx, hash
func (*MockClient) TestConnection ¶
func (_m *MockClient) TestConnection(ctx context.Context) error
TestConnection provides a mock function with given fields: ctx
type MockClient_AddTorrent_Call ¶
MockClient_AddTorrent_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'AddTorrent'
func (*MockClient_AddTorrent_Call) Return ¶
func (_c *MockClient_AddTorrent_Call) Return(_a0 string, _a1 error) *MockClient_AddTorrent_Call
func (*MockClient_AddTorrent_Call) Run ¶
func (_c *MockClient_AddTorrent_Call) Run(run func(ctx context.Context, src download.TorrentSource)) *MockClient_AddTorrent_Call
func (*MockClient_AddTorrent_Call) RunAndReturn ¶
func (_c *MockClient_AddTorrent_Call) RunAndReturn(run func(context.Context, download.TorrentSource) (string, error)) *MockClient_AddTorrent_Call
type MockClient_Expecter ¶
type MockClient_Expecter struct {
// contains filtered or unexported fields
}
func (*MockClient_Expecter) AddTorrent ¶
func (_e *MockClient_Expecter) AddTorrent(ctx interface{}, src interface{}) *MockClient_AddTorrent_Call
AddTorrent is a helper method to define mock.On call
- ctx context.Context
- src download.TorrentSource
func (*MockClient_Expecter) GetTorrent ¶
func (_e *MockClient_Expecter) GetTorrent(ctx interface{}, hash interface{}) *MockClient_GetTorrent_Call
GetTorrent is a helper method to define mock.On call
- ctx context.Context
- hash string
func (*MockClient_Expecter) ListTorrents ¶
func (_e *MockClient_Expecter) ListTorrents(ctx interface{}) *MockClient_ListTorrents_Call
ListTorrents is a helper method to define mock.On call
- ctx context.Context
func (*MockClient_Expecter) PauseTorrent ¶
func (_e *MockClient_Expecter) PauseTorrent(ctx interface{}, hash interface{}) *MockClient_PauseTorrent_Call
PauseTorrent is a helper method to define mock.On call
- ctx context.Context
- hash string
func (*MockClient_Expecter) RemoveTorrent ¶
func (_e *MockClient_Expecter) RemoveTorrent(ctx interface{}, hash interface{}, deleteFiles interface{}) *MockClient_RemoveTorrent_Call
RemoveTorrent is a helper method to define mock.On call
- ctx context.Context
- hash string
- deleteFiles bool
func (*MockClient_Expecter) ResumeTorrent ¶
func (_e *MockClient_Expecter) ResumeTorrent(ctx interface{}, hash interface{}) *MockClient_ResumeTorrent_Call
ResumeTorrent is a helper method to define mock.On call
- ctx context.Context
- hash string
func (*MockClient_Expecter) TestConnection ¶
func (_e *MockClient_Expecter) TestConnection(ctx interface{}) *MockClient_TestConnection_Call
TestConnection is a helper method to define mock.On call
- ctx context.Context
type MockClient_GetTorrent_Call ¶
MockClient_GetTorrent_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetTorrent'
func (*MockClient_GetTorrent_Call) Return ¶
func (_c *MockClient_GetTorrent_Call) Return(_a0 *download.Torrent, _a1 error) *MockClient_GetTorrent_Call
func (*MockClient_GetTorrent_Call) Run ¶
func (_c *MockClient_GetTorrent_Call) Run(run func(ctx context.Context, hash string)) *MockClient_GetTorrent_Call
func (*MockClient_GetTorrent_Call) RunAndReturn ¶
func (_c *MockClient_GetTorrent_Call) RunAndReturn(run func(context.Context, string) (*download.Torrent, error)) *MockClient_GetTorrent_Call
type MockClient_ListTorrents_Call ¶
MockClient_ListTorrents_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListTorrents'
func (*MockClient_ListTorrents_Call) Return ¶
func (_c *MockClient_ListTorrents_Call) Return(_a0 []download.Torrent, _a1 error) *MockClient_ListTorrents_Call
func (*MockClient_ListTorrents_Call) Run ¶
func (_c *MockClient_ListTorrents_Call) Run(run func(ctx context.Context)) *MockClient_ListTorrents_Call
func (*MockClient_ListTorrents_Call) RunAndReturn ¶
func (_c *MockClient_ListTorrents_Call) RunAndReturn(run func(context.Context) ([]download.Torrent, error)) *MockClient_ListTorrents_Call
type MockClient_PauseTorrent_Call ¶
MockClient_PauseTorrent_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'PauseTorrent'
func (*MockClient_PauseTorrent_Call) Return ¶
func (_c *MockClient_PauseTorrent_Call) Return(_a0 error) *MockClient_PauseTorrent_Call
func (*MockClient_PauseTorrent_Call) Run ¶
func (_c *MockClient_PauseTorrent_Call) Run(run func(ctx context.Context, hash string)) *MockClient_PauseTorrent_Call
func (*MockClient_PauseTorrent_Call) RunAndReturn ¶
func (_c *MockClient_PauseTorrent_Call) RunAndReturn(run func(context.Context, string) error) *MockClient_PauseTorrent_Call
type MockClient_RemoveTorrent_Call ¶
MockClient_RemoveTorrent_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RemoveTorrent'
func (*MockClient_RemoveTorrent_Call) Return ¶
func (_c *MockClient_RemoveTorrent_Call) Return(_a0 error) *MockClient_RemoveTorrent_Call
func (*MockClient_RemoveTorrent_Call) Run ¶
func (_c *MockClient_RemoveTorrent_Call) Run(run func(ctx context.Context, hash string, deleteFiles bool)) *MockClient_RemoveTorrent_Call
func (*MockClient_RemoveTorrent_Call) RunAndReturn ¶
func (_c *MockClient_RemoveTorrent_Call) RunAndReturn(run func(context.Context, string, bool) error) *MockClient_RemoveTorrent_Call
type MockClient_ResumeTorrent_Call ¶
MockClient_ResumeTorrent_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ResumeTorrent'
func (*MockClient_ResumeTorrent_Call) Return ¶
func (_c *MockClient_ResumeTorrent_Call) Return(_a0 error) *MockClient_ResumeTorrent_Call
func (*MockClient_ResumeTorrent_Call) Run ¶
func (_c *MockClient_ResumeTorrent_Call) Run(run func(ctx context.Context, hash string)) *MockClient_ResumeTorrent_Call
func (*MockClient_ResumeTorrent_Call) RunAndReturn ¶
func (_c *MockClient_ResumeTorrent_Call) RunAndReturn(run func(context.Context, string) error) *MockClient_ResumeTorrent_Call
type MockClient_TestConnection_Call ¶
MockClient_TestConnection_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'TestConnection'
func (*MockClient_TestConnection_Call) Return ¶
func (_c *MockClient_TestConnection_Call) Return(_a0 error) *MockClient_TestConnection_Call
func (*MockClient_TestConnection_Call) Run ¶
func (_c *MockClient_TestConnection_Call) Run(run func(ctx context.Context)) *MockClient_TestConnection_Call
func (*MockClient_TestConnection_Call) RunAndReturn ¶
func (_c *MockClient_TestConnection_Call) RunAndReturn(run func(context.Context) error) *MockClient_TestConnection_Call
type MockDownloader ¶
MockDownloader is an autogenerated mock type for the Downloader type
func NewMockDownloader ¶
func NewMockDownloader(t interface {
mock.TestingT
Cleanup(func())
}) *MockDownloader
NewMockDownloader creates a new instance of MockDownloader. 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 (*MockDownloader) CancelQueueItem ¶
func (_m *MockDownloader) CancelQueueItem(ctx context.Context, recordID uint32) error
CancelQueueItem provides a mock function with given fields: ctx, recordID
func (*MockDownloader) CheckStatus ¶
func (_m *MockDownloader) CheckStatus(ctx context.Context) ([]download.CompletedDownload, error)
CheckStatus provides a mock function with given fields: ctx
func (*MockDownloader) EXPECT ¶
func (_m *MockDownloader) EXPECT() *MockDownloader_Expecter
func (*MockDownloader) Grab ¶
func (_m *MockDownloader) Grab(ctx context.Context, result indexer.SearchResult, movieID uint32) (*ent.DownloadRecord, error)
Grab provides a mock function with given fields: ctx, result, movieID
func (*MockDownloader) GrabEpisode ¶
func (_m *MockDownloader) GrabEpisode(ctx context.Context, result indexer.SearchResult, episodeID uint32) (*ent.DownloadRecord, error)
GrabEpisode provides a mock function with given fields: ctx, result, episodeID
func (*MockDownloader) PauseQueueItem ¶
func (_m *MockDownloader) PauseQueueItem(ctx context.Context, recordID uint32) error
PauseQueueItem provides a mock function with given fields: ctx, recordID
func (*MockDownloader) Queue ¶
func (_m *MockDownloader) Queue(ctx context.Context) (download.QueueSnapshot, error)
Queue provides a mock function with given fields: ctx
func (*MockDownloader) ReconcileEpisodeStatuses ¶
func (_m *MockDownloader) ReconcileEpisodeStatuses(ctx context.Context) error
ReconcileEpisodeStatuses provides a mock function with given fields: ctx
func (*MockDownloader) RemoveTorrent ¶
func (_m *MockDownloader) RemoveTorrent(ctx context.Context, downloadClientName string, torrentHash string) error
RemoveTorrent provides a mock function with given fields: ctx, downloadClientName, torrentHash
func (*MockDownloader) ResumeQueueItem ¶
func (_m *MockDownloader) ResumeQueueItem(ctx context.Context, recordID uint32) error
ResumeQueueItem provides a mock function with given fields: ctx, recordID
func (*MockDownloader) Test ¶
func (_m *MockDownloader) Test(ctx context.Context, p download.TestParams) error
Test provides a mock function with given fields: ctx, p
func (*MockDownloader) TestByName ¶
func (_m *MockDownloader) TestByName(ctx context.Context, name string) error
TestByName provides a mock function with given fields: ctx, name
type MockDownloader_CancelQueueItem_Call ¶
MockDownloader_CancelQueueItem_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CancelQueueItem'
func (*MockDownloader_CancelQueueItem_Call) Return ¶
func (_c *MockDownloader_CancelQueueItem_Call) Return(_a0 error) *MockDownloader_CancelQueueItem_Call
func (*MockDownloader_CancelQueueItem_Call) Run ¶
func (_c *MockDownloader_CancelQueueItem_Call) Run(run func(ctx context.Context, recordID uint32)) *MockDownloader_CancelQueueItem_Call
func (*MockDownloader_CancelQueueItem_Call) RunAndReturn ¶
func (_c *MockDownloader_CancelQueueItem_Call) RunAndReturn(run func(context.Context, uint32) error) *MockDownloader_CancelQueueItem_Call
type MockDownloader_CheckStatus_Call ¶
MockDownloader_CheckStatus_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CheckStatus'
func (*MockDownloader_CheckStatus_Call) Return ¶
func (_c *MockDownloader_CheckStatus_Call) Return(_a0 []download.CompletedDownload, _a1 error) *MockDownloader_CheckStatus_Call
func (*MockDownloader_CheckStatus_Call) Run ¶
func (_c *MockDownloader_CheckStatus_Call) Run(run func(ctx context.Context)) *MockDownloader_CheckStatus_Call
func (*MockDownloader_CheckStatus_Call) RunAndReturn ¶
func (_c *MockDownloader_CheckStatus_Call) RunAndReturn(run func(context.Context) ([]download.CompletedDownload, error)) *MockDownloader_CheckStatus_Call
type MockDownloader_Expecter ¶
type MockDownloader_Expecter struct {
// contains filtered or unexported fields
}
func (*MockDownloader_Expecter) CancelQueueItem ¶
func (_e *MockDownloader_Expecter) CancelQueueItem(ctx interface{}, recordID interface{}) *MockDownloader_CancelQueueItem_Call
CancelQueueItem is a helper method to define mock.On call
- ctx context.Context
- recordID uint32
func (*MockDownloader_Expecter) CheckStatus ¶
func (_e *MockDownloader_Expecter) CheckStatus(ctx interface{}) *MockDownloader_CheckStatus_Call
CheckStatus is a helper method to define mock.On call
- ctx context.Context
func (*MockDownloader_Expecter) Grab ¶
func (_e *MockDownloader_Expecter) Grab(ctx interface{}, result interface{}, movieID interface{}) *MockDownloader_Grab_Call
Grab is a helper method to define mock.On call
- ctx context.Context
- result indexer.SearchResult
- movieID uint32
func (*MockDownloader_Expecter) GrabEpisode ¶
func (_e *MockDownloader_Expecter) GrabEpisode(ctx interface{}, result interface{}, episodeID interface{}) *MockDownloader_GrabEpisode_Call
GrabEpisode is a helper method to define mock.On call
- ctx context.Context
- result indexer.SearchResult
- episodeID uint32
func (*MockDownloader_Expecter) PauseQueueItem ¶
func (_e *MockDownloader_Expecter) PauseQueueItem(ctx interface{}, recordID interface{}) *MockDownloader_PauseQueueItem_Call
PauseQueueItem is a helper method to define mock.On call
- ctx context.Context
- recordID uint32
func (*MockDownloader_Expecter) Queue ¶
func (_e *MockDownloader_Expecter) Queue(ctx interface{}) *MockDownloader_Queue_Call
Queue is a helper method to define mock.On call
- ctx context.Context
func (*MockDownloader_Expecter) ReconcileEpisodeStatuses ¶
func (_e *MockDownloader_Expecter) ReconcileEpisodeStatuses(ctx interface{}) *MockDownloader_ReconcileEpisodeStatuses_Call
ReconcileEpisodeStatuses is a helper method to define mock.On call
- ctx context.Context
func (*MockDownloader_Expecter) RemoveTorrent ¶
func (_e *MockDownloader_Expecter) RemoveTorrent(ctx interface{}, downloadClientName interface{}, torrentHash interface{}) *MockDownloader_RemoveTorrent_Call
RemoveTorrent is a helper method to define mock.On call
- ctx context.Context
- downloadClientName string
- torrentHash string
func (*MockDownloader_Expecter) ResumeQueueItem ¶
func (_e *MockDownloader_Expecter) ResumeQueueItem(ctx interface{}, recordID interface{}) *MockDownloader_ResumeQueueItem_Call
ResumeQueueItem is a helper method to define mock.On call
- ctx context.Context
- recordID uint32
func (*MockDownloader_Expecter) Test ¶
func (_e *MockDownloader_Expecter) Test(ctx interface{}, p interface{}) *MockDownloader_Test_Call
Test is a helper method to define mock.On call
- ctx context.Context
- p download.TestParams
func (*MockDownloader_Expecter) TestByName ¶
func (_e *MockDownloader_Expecter) TestByName(ctx interface{}, name interface{}) *MockDownloader_TestByName_Call
TestByName is a helper method to define mock.On call
- ctx context.Context
- name string
type MockDownloader_GrabEpisode_Call ¶
MockDownloader_GrabEpisode_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GrabEpisode'
func (*MockDownloader_GrabEpisode_Call) Return ¶
func (_c *MockDownloader_GrabEpisode_Call) Return(_a0 *ent.DownloadRecord, _a1 error) *MockDownloader_GrabEpisode_Call
func (*MockDownloader_GrabEpisode_Call) Run ¶
func (_c *MockDownloader_GrabEpisode_Call) Run(run func(ctx context.Context, result indexer.SearchResult, episodeID uint32)) *MockDownloader_GrabEpisode_Call
func (*MockDownloader_GrabEpisode_Call) RunAndReturn ¶
func (_c *MockDownloader_GrabEpisode_Call) RunAndReturn(run func(context.Context, indexer.SearchResult, uint32) (*ent.DownloadRecord, error)) *MockDownloader_GrabEpisode_Call
type MockDownloader_Grab_Call ¶
MockDownloader_Grab_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Grab'
func (*MockDownloader_Grab_Call) Return ¶
func (_c *MockDownloader_Grab_Call) Return(_a0 *ent.DownloadRecord, _a1 error) *MockDownloader_Grab_Call
func (*MockDownloader_Grab_Call) Run ¶
func (_c *MockDownloader_Grab_Call) Run(run func(ctx context.Context, result indexer.SearchResult, movieID uint32)) *MockDownloader_Grab_Call
func (*MockDownloader_Grab_Call) RunAndReturn ¶
func (_c *MockDownloader_Grab_Call) RunAndReturn(run func(context.Context, indexer.SearchResult, uint32) (*ent.DownloadRecord, error)) *MockDownloader_Grab_Call
type MockDownloader_PauseQueueItem_Call ¶
MockDownloader_PauseQueueItem_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'PauseQueueItem'
func (*MockDownloader_PauseQueueItem_Call) Return ¶
func (_c *MockDownloader_PauseQueueItem_Call) Return(_a0 error) *MockDownloader_PauseQueueItem_Call
func (*MockDownloader_PauseQueueItem_Call) Run ¶
func (_c *MockDownloader_PauseQueueItem_Call) Run(run func(ctx context.Context, recordID uint32)) *MockDownloader_PauseQueueItem_Call
func (*MockDownloader_PauseQueueItem_Call) RunAndReturn ¶
func (_c *MockDownloader_PauseQueueItem_Call) RunAndReturn(run func(context.Context, uint32) error) *MockDownloader_PauseQueueItem_Call
type MockDownloader_Queue_Call ¶
MockDownloader_Queue_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Queue'
func (*MockDownloader_Queue_Call) Return ¶
func (_c *MockDownloader_Queue_Call) Return(_a0 download.QueueSnapshot, _a1 error) *MockDownloader_Queue_Call
func (*MockDownloader_Queue_Call) Run ¶
func (_c *MockDownloader_Queue_Call) Run(run func(ctx context.Context)) *MockDownloader_Queue_Call
func (*MockDownloader_Queue_Call) RunAndReturn ¶
func (_c *MockDownloader_Queue_Call) RunAndReturn(run func(context.Context) (download.QueueSnapshot, error)) *MockDownloader_Queue_Call
type MockDownloader_ReconcileEpisodeStatuses_Call ¶
MockDownloader_ReconcileEpisodeStatuses_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ReconcileEpisodeStatuses'
func (*MockDownloader_ReconcileEpisodeStatuses_Call) Return ¶
func (_c *MockDownloader_ReconcileEpisodeStatuses_Call) Return(_a0 error) *MockDownloader_ReconcileEpisodeStatuses_Call
func (*MockDownloader_ReconcileEpisodeStatuses_Call) Run ¶
func (_c *MockDownloader_ReconcileEpisodeStatuses_Call) Run(run func(ctx context.Context)) *MockDownloader_ReconcileEpisodeStatuses_Call
func (*MockDownloader_ReconcileEpisodeStatuses_Call) RunAndReturn ¶
func (_c *MockDownloader_ReconcileEpisodeStatuses_Call) RunAndReturn(run func(context.Context) error) *MockDownloader_ReconcileEpisodeStatuses_Call
type MockDownloader_RemoveTorrent_Call ¶
MockDownloader_RemoveTorrent_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RemoveTorrent'
func (*MockDownloader_RemoveTorrent_Call) Return ¶
func (_c *MockDownloader_RemoveTorrent_Call) Return(_a0 error) *MockDownloader_RemoveTorrent_Call
func (*MockDownloader_RemoveTorrent_Call) Run ¶
func (_c *MockDownloader_RemoveTorrent_Call) Run(run func(ctx context.Context, downloadClientName string, torrentHash string)) *MockDownloader_RemoveTorrent_Call
func (*MockDownloader_RemoveTorrent_Call) RunAndReturn ¶
func (_c *MockDownloader_RemoveTorrent_Call) RunAndReturn(run func(context.Context, string, string) error) *MockDownloader_RemoveTorrent_Call
type MockDownloader_ResumeQueueItem_Call ¶
MockDownloader_ResumeQueueItem_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ResumeQueueItem'
func (*MockDownloader_ResumeQueueItem_Call) Return ¶
func (_c *MockDownloader_ResumeQueueItem_Call) Return(_a0 error) *MockDownloader_ResumeQueueItem_Call
func (*MockDownloader_ResumeQueueItem_Call) Run ¶
func (_c *MockDownloader_ResumeQueueItem_Call) Run(run func(ctx context.Context, recordID uint32)) *MockDownloader_ResumeQueueItem_Call
func (*MockDownloader_ResumeQueueItem_Call) RunAndReturn ¶
func (_c *MockDownloader_ResumeQueueItem_Call) RunAndReturn(run func(context.Context, uint32) error) *MockDownloader_ResumeQueueItem_Call
type MockDownloader_TestByName_Call ¶
MockDownloader_TestByName_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'TestByName'
func (*MockDownloader_TestByName_Call) Return ¶
func (_c *MockDownloader_TestByName_Call) Return(_a0 error) *MockDownloader_TestByName_Call
func (*MockDownloader_TestByName_Call) Run ¶
func (_c *MockDownloader_TestByName_Call) Run(run func(ctx context.Context, name string)) *MockDownloader_TestByName_Call
func (*MockDownloader_TestByName_Call) RunAndReturn ¶
func (_c *MockDownloader_TestByName_Call) RunAndReturn(run func(context.Context, string) error) *MockDownloader_TestByName_Call
type MockDownloader_Test_Call ¶
MockDownloader_Test_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Test'
func (*MockDownloader_Test_Call) Return ¶
func (_c *MockDownloader_Test_Call) Return(_a0 error) *MockDownloader_Test_Call
func (*MockDownloader_Test_Call) Run ¶
func (_c *MockDownloader_Test_Call) Run(run func(ctx context.Context, p download.TestParams)) *MockDownloader_Test_Call
func (*MockDownloader_Test_Call) RunAndReturn ¶
func (_c *MockDownloader_Test_Call) RunAndReturn(run func(context.Context, download.TestParams) error) *MockDownloader_Test_Call