Documentation
¶
Index ¶
- type MockAPIKeyService
- func (_mock *MockAPIKeyService) Create(ctx context.Context, principal kernel.Principal, name string) (string, *apikey.APIKey, error)
- func (_m *MockAPIKeyService) EXPECT() *MockAPIKeyService_Expecter
- func (_mock *MockAPIKeyService) List(ctx context.Context, principal kernel.Principal) ([]*apikey.APIKey, error)
- func (_mock *MockAPIKeyService) Revoke(ctx context.Context, id int, principal kernel.Principal) (*apikey.APIKey, error)
- type MockAPIKeyService_Create_Call
- func (_c *MockAPIKeyService_Create_Call) Return(s string, aPIKey *apikey.APIKey, err error) *MockAPIKeyService_Create_Call
- func (_c *MockAPIKeyService_Create_Call) Run(run func(ctx context.Context, principal kernel.Principal, name string)) *MockAPIKeyService_Create_Call
- func (_c *MockAPIKeyService_Create_Call) RunAndReturn(...) *MockAPIKeyService_Create_Call
- type MockAPIKeyService_Expecter
- func (_e *MockAPIKeyService_Expecter) Create(ctx any, principal any, name any) *MockAPIKeyService_Create_Call
- func (_e *MockAPIKeyService_Expecter) List(ctx any, principal any) *MockAPIKeyService_List_Call
- func (_e *MockAPIKeyService_Expecter) Revoke(ctx any, id any, principal any) *MockAPIKeyService_Revoke_Call
- type MockAPIKeyService_List_Call
- func (_c *MockAPIKeyService_List_Call) Return(aPIKeys []*apikey.APIKey, err error) *MockAPIKeyService_List_Call
- func (_c *MockAPIKeyService_List_Call) Run(run func(ctx context.Context, principal kernel.Principal)) *MockAPIKeyService_List_Call
- func (_c *MockAPIKeyService_List_Call) RunAndReturn(...) *MockAPIKeyService_List_Call
- type MockAPIKeyService_Revoke_Call
- func (_c *MockAPIKeyService_Revoke_Call) Return(aPIKey *apikey.APIKey, err error) *MockAPIKeyService_Revoke_Call
- func (_c *MockAPIKeyService_Revoke_Call) Run(run func(ctx context.Context, id int, principal kernel.Principal)) *MockAPIKeyService_Revoke_Call
- func (_c *MockAPIKeyService_Revoke_Call) RunAndReturn(...) *MockAPIKeyService_Revoke_Call
- type MockContentServiceInterface
- func (_mock *MockContentServiceInterface) AuthorExists(ctx context.Context, username string) (bool, error)
- func (_mock *MockContentServiceInterface) Count(ctx context.Context, userID int, filters content.ContentFilters) (int, error)
- func (_mock *MockContentServiceInterface) Create(ctx context.Context, principal kernel.Principal, ...) (*content.Content, error)
- func (_mock *MockContentServiceInterface) DeleteContent(ctx context.Context, id int, principal kernel.Principal) error
- func (_m *MockContentServiceInterface) EXPECT() *MockContentServiceInterface_Expecter
- func (_mock *MockContentServiceInterface) GenerateSlugFromTitle(ctx context.Context, title string) (string, error)
- func (_mock *MockContentServiceInterface) GetAll(ctx context.Context, limit int, offset int) ([]*content.Content, error)
- func (_mock *MockContentServiceInterface) GetByID(ctx context.Context, id int) (*content.Content, error)
- func (_mock *MockContentServiceInterface) GetByUser(ctx context.Context, userID int, limit int, offset int) ([]*content.Content, error)
- func (_mock *MockContentServiceInterface) GetPublished(ctx context.Context, limit int, offset int) ([]*content.Content, error)
- func (_mock *MockContentServiceInterface) GetPublishedArchive(ctx context.Context, postType string, languages []string) ([]*content.ArchiveMonth, error)
- func (_mock *MockContentServiceInterface) GetPublishedAuthor(ctx context.Context, username string) (*content.PublishedAuthor, error)
- func (_mock *MockContentServiceInterface) GetPublishedAuthors(ctx context.Context, filters content.PublishedAuthorFilters) ([]*content.PublishedAuthor, error)
- func (_mock *MockContentServiceInterface) GetPublishedByAuthorUsername(ctx context.Context, username string, languages []string, limit int, ...) ([]*content.Content, error)
- func (_mock *MockContentServiceInterface) GetPublishedByPostType(ctx context.Context, postType string, languages []string, year int, month int, ...) ([]*content.Content, error)
- func (_mock *MockContentServiceInterface) GetPublishedBySlug(ctx context.Context, slug string, language string) (*content.Content, error)
- func (_mock *MockContentServiceInterface) GetTranslations(ctx context.Context, translationGroupID int, excludeID int) ([]*content.Content, error)
- func (_mock *MockContentServiceInterface) ListByFilters(ctx context.Context, userID int, filters content.ContentFilters) ([]*content.Content, error)
- func (_mock *MockContentServiceInterface) SearchPublished(ctx context.Context, query string, limit int) ([]*content.Content, error)
- func (_mock *MockContentServiceInterface) SetSystemFields(ctx context.Context, contentID int, principal kernel.Principal, ...) (*content.Content, error)
- func (_mock *MockContentServiceInterface) Update(ctx context.Context, id int, principal kernel.Principal, ...) (*content.Content, error)
- type MockContentServiceInterface_AuthorExists_Call
- func (_c *MockContentServiceInterface_AuthorExists_Call) Return(b bool, err error) *MockContentServiceInterface_AuthorExists_Call
- func (_c *MockContentServiceInterface_AuthorExists_Call) Run(run func(ctx context.Context, username string)) *MockContentServiceInterface_AuthorExists_Call
- func (_c *MockContentServiceInterface_AuthorExists_Call) RunAndReturn(run func(ctx context.Context, username string) (bool, error)) *MockContentServiceInterface_AuthorExists_Call
- type MockContentServiceInterface_Count_Call
- func (_c *MockContentServiceInterface_Count_Call) Return(n int, err error) *MockContentServiceInterface_Count_Call
- func (_c *MockContentServiceInterface_Count_Call) Run(run func(ctx context.Context, userID int, filters content.ContentFilters)) *MockContentServiceInterface_Count_Call
- func (_c *MockContentServiceInterface_Count_Call) RunAndReturn(...) *MockContentServiceInterface_Count_Call
- type MockContentServiceInterface_Create_Call
- func (_c *MockContentServiceInterface_Create_Call) Return(content1 *content.Content, err error) *MockContentServiceInterface_Create_Call
- func (_c *MockContentServiceInterface_Create_Call) Run(run func(ctx context.Context, principal kernel.Principal, ...)) *MockContentServiceInterface_Create_Call
- func (_c *MockContentServiceInterface_Create_Call) RunAndReturn(...) *MockContentServiceInterface_Create_Call
- type MockContentServiceInterface_DeleteContent_Call
- func (_c *MockContentServiceInterface_DeleteContent_Call) Return(err error) *MockContentServiceInterface_DeleteContent_Call
- func (_c *MockContentServiceInterface_DeleteContent_Call) Run(run func(ctx context.Context, id int, principal kernel.Principal)) *MockContentServiceInterface_DeleteContent_Call
- func (_c *MockContentServiceInterface_DeleteContent_Call) RunAndReturn(run func(ctx context.Context, id int, principal kernel.Principal) error) *MockContentServiceInterface_DeleteContent_Call
- type MockContentServiceInterface_Expecter
- func (_e *MockContentServiceInterface_Expecter) AuthorExists(ctx any, username any) *MockContentServiceInterface_AuthorExists_Call
- func (_e *MockContentServiceInterface_Expecter) Count(ctx any, userID any, filters any) *MockContentServiceInterface_Count_Call
- func (_e *MockContentServiceInterface_Expecter) Create(ctx any, principal any, req any) *MockContentServiceInterface_Create_Call
- func (_e *MockContentServiceInterface_Expecter) DeleteContent(ctx any, id any, principal any) *MockContentServiceInterface_DeleteContent_Call
- func (_e *MockContentServiceInterface_Expecter) GenerateSlugFromTitle(ctx any, title any) *MockContentServiceInterface_GenerateSlugFromTitle_Call
- func (_e *MockContentServiceInterface_Expecter) GetAll(ctx any, limit any, offset any) *MockContentServiceInterface_GetAll_Call
- func (_e *MockContentServiceInterface_Expecter) GetByID(ctx any, id any) *MockContentServiceInterface_GetByID_Call
- func (_e *MockContentServiceInterface_Expecter) GetByUser(ctx any, userID any, limit any, offset any) *MockContentServiceInterface_GetByUser_Call
- func (_e *MockContentServiceInterface_Expecter) GetPublished(ctx any, limit any, offset any) *MockContentServiceInterface_GetPublished_Call
- func (_e *MockContentServiceInterface_Expecter) GetPublishedArchive(ctx any, postType any, languages any) *MockContentServiceInterface_GetPublishedArchive_Call
- func (_e *MockContentServiceInterface_Expecter) GetPublishedAuthor(ctx any, username any) *MockContentServiceInterface_GetPublishedAuthor_Call
- func (_e *MockContentServiceInterface_Expecter) GetPublishedAuthors(ctx any, filters any) *MockContentServiceInterface_GetPublishedAuthors_Call
- func (_e *MockContentServiceInterface_Expecter) GetPublishedByAuthorUsername(ctx any, username any, languages any, limit any, offset any) *MockContentServiceInterface_GetPublishedByAuthorUsername_Call
- func (_e *MockContentServiceInterface_Expecter) GetPublishedByPostType(ctx any, postType any, languages any, year any, month any, limit any, ...) *MockContentServiceInterface_GetPublishedByPostType_Call
- func (_e *MockContentServiceInterface_Expecter) GetPublishedBySlug(ctx any, slug any, language any) *MockContentServiceInterface_GetPublishedBySlug_Call
- func (_e *MockContentServiceInterface_Expecter) GetTranslations(ctx any, translationGroupID any, excludeID any) *MockContentServiceInterface_GetTranslations_Call
- func (_e *MockContentServiceInterface_Expecter) ListByFilters(ctx any, userID any, filters any) *MockContentServiceInterface_ListByFilters_Call
- func (_e *MockContentServiceInterface_Expecter) SearchPublished(ctx any, query any, limit any) *MockContentServiceInterface_SearchPublished_Call
- func (_e *MockContentServiceInterface_Expecter) SetSystemFields(ctx any, contentID any, principal any, systemFields any) *MockContentServiceInterface_SetSystemFields_Call
- func (_e *MockContentServiceInterface_Expecter) Update(ctx any, id any, principal any, req any) *MockContentServiceInterface_Update_Call
- type MockContentServiceInterface_GenerateSlugFromTitle_Call
- func (_c *MockContentServiceInterface_GenerateSlugFromTitle_Call) Return(s string, err error) *MockContentServiceInterface_GenerateSlugFromTitle_Call
- func (_c *MockContentServiceInterface_GenerateSlugFromTitle_Call) Run(run func(ctx context.Context, title string)) *MockContentServiceInterface_GenerateSlugFromTitle_Call
- func (_c *MockContentServiceInterface_GenerateSlugFromTitle_Call) RunAndReturn(run func(ctx context.Context, title string) (string, error)) *MockContentServiceInterface_GenerateSlugFromTitle_Call
- type MockContentServiceInterface_GetAll_Call
- func (_c *MockContentServiceInterface_GetAll_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_GetAll_Call
- func (_c *MockContentServiceInterface_GetAll_Call) Run(run func(ctx context.Context, limit int, offset int)) *MockContentServiceInterface_GetAll_Call
- func (_c *MockContentServiceInterface_GetAll_Call) RunAndReturn(...) *MockContentServiceInterface_GetAll_Call
- type MockContentServiceInterface_GetByID_Call
- func (_c *MockContentServiceInterface_GetByID_Call) Return(content1 *content.Content, err error) *MockContentServiceInterface_GetByID_Call
- func (_c *MockContentServiceInterface_GetByID_Call) Run(run func(ctx context.Context, id int)) *MockContentServiceInterface_GetByID_Call
- func (_c *MockContentServiceInterface_GetByID_Call) RunAndReturn(run func(ctx context.Context, id int) (*content.Content, error)) *MockContentServiceInterface_GetByID_Call
- type MockContentServiceInterface_GetByUser_Call
- func (_c *MockContentServiceInterface_GetByUser_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_GetByUser_Call
- func (_c *MockContentServiceInterface_GetByUser_Call) Run(run func(ctx context.Context, userID int, limit int, offset int)) *MockContentServiceInterface_GetByUser_Call
- func (_c *MockContentServiceInterface_GetByUser_Call) RunAndReturn(...) *MockContentServiceInterface_GetByUser_Call
- type MockContentServiceInterface_GetPublishedArchive_Call
- func (_c *MockContentServiceInterface_GetPublishedArchive_Call) Return(archiveMonths []*content.ArchiveMonth, err error) *MockContentServiceInterface_GetPublishedArchive_Call
- func (_c *MockContentServiceInterface_GetPublishedArchive_Call) Run(run func(ctx context.Context, postType string, languages []string)) *MockContentServiceInterface_GetPublishedArchive_Call
- func (_c *MockContentServiceInterface_GetPublishedArchive_Call) RunAndReturn(...) *MockContentServiceInterface_GetPublishedArchive_Call
- type MockContentServiceInterface_GetPublishedAuthor_Call
- func (_c *MockContentServiceInterface_GetPublishedAuthor_Call) Return(publishedAuthor *content.PublishedAuthor, err error) *MockContentServiceInterface_GetPublishedAuthor_Call
- func (_c *MockContentServiceInterface_GetPublishedAuthor_Call) Run(run func(ctx context.Context, username string)) *MockContentServiceInterface_GetPublishedAuthor_Call
- func (_c *MockContentServiceInterface_GetPublishedAuthor_Call) RunAndReturn(...) *MockContentServiceInterface_GetPublishedAuthor_Call
- type MockContentServiceInterface_GetPublishedAuthors_Call
- func (_c *MockContentServiceInterface_GetPublishedAuthors_Call) Return(publishedAuthors []*content.PublishedAuthor, err error) *MockContentServiceInterface_GetPublishedAuthors_Call
- func (_c *MockContentServiceInterface_GetPublishedAuthors_Call) Run(run func(ctx context.Context, filters content.PublishedAuthorFilters)) *MockContentServiceInterface_GetPublishedAuthors_Call
- func (_c *MockContentServiceInterface_GetPublishedAuthors_Call) RunAndReturn(...) *MockContentServiceInterface_GetPublishedAuthors_Call
- type MockContentServiceInterface_GetPublishedByAuthorUsername_Call
- func (_c *MockContentServiceInterface_GetPublishedByAuthorUsername_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_GetPublishedByAuthorUsername_Call
- func (_c *MockContentServiceInterface_GetPublishedByAuthorUsername_Call) Run(...) *MockContentServiceInterface_GetPublishedByAuthorUsername_Call
- func (_c *MockContentServiceInterface_GetPublishedByAuthorUsername_Call) RunAndReturn(...) *MockContentServiceInterface_GetPublishedByAuthorUsername_Call
- type MockContentServiceInterface_GetPublishedByPostType_Call
- func (_c *MockContentServiceInterface_GetPublishedByPostType_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_GetPublishedByPostType_Call
- func (_c *MockContentServiceInterface_GetPublishedByPostType_Call) Run(...) *MockContentServiceInterface_GetPublishedByPostType_Call
- func (_c *MockContentServiceInterface_GetPublishedByPostType_Call) RunAndReturn(...) *MockContentServiceInterface_GetPublishedByPostType_Call
- type MockContentServiceInterface_GetPublishedBySlug_Call
- func (_c *MockContentServiceInterface_GetPublishedBySlug_Call) Return(content1 *content.Content, err error) *MockContentServiceInterface_GetPublishedBySlug_Call
- func (_c *MockContentServiceInterface_GetPublishedBySlug_Call) Run(run func(ctx context.Context, slug string, language string)) *MockContentServiceInterface_GetPublishedBySlug_Call
- func (_c *MockContentServiceInterface_GetPublishedBySlug_Call) RunAndReturn(...) *MockContentServiceInterface_GetPublishedBySlug_Call
- type MockContentServiceInterface_GetPublished_Call
- func (_c *MockContentServiceInterface_GetPublished_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_GetPublished_Call
- func (_c *MockContentServiceInterface_GetPublished_Call) Run(run func(ctx context.Context, limit int, offset int)) *MockContentServiceInterface_GetPublished_Call
- func (_c *MockContentServiceInterface_GetPublished_Call) RunAndReturn(...) *MockContentServiceInterface_GetPublished_Call
- type MockContentServiceInterface_GetTranslations_Call
- func (_c *MockContentServiceInterface_GetTranslations_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_GetTranslations_Call
- func (_c *MockContentServiceInterface_GetTranslations_Call) Run(run func(ctx context.Context, translationGroupID int, excludeID int)) *MockContentServiceInterface_GetTranslations_Call
- func (_c *MockContentServiceInterface_GetTranslations_Call) RunAndReturn(...) *MockContentServiceInterface_GetTranslations_Call
- type MockContentServiceInterface_ListByFilters_Call
- func (_c *MockContentServiceInterface_ListByFilters_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_ListByFilters_Call
- func (_c *MockContentServiceInterface_ListByFilters_Call) Run(run func(ctx context.Context, userID int, filters content.ContentFilters)) *MockContentServiceInterface_ListByFilters_Call
- func (_c *MockContentServiceInterface_ListByFilters_Call) RunAndReturn(...) *MockContentServiceInterface_ListByFilters_Call
- type MockContentServiceInterface_SearchPublished_Call
- func (_c *MockContentServiceInterface_SearchPublished_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_SearchPublished_Call
- func (_c *MockContentServiceInterface_SearchPublished_Call) Run(run func(ctx context.Context, query string, limit int)) *MockContentServiceInterface_SearchPublished_Call
- func (_c *MockContentServiceInterface_SearchPublished_Call) RunAndReturn(...) *MockContentServiceInterface_SearchPublished_Call
- type MockContentServiceInterface_SetSystemFields_Call
- func (_c *MockContentServiceInterface_SetSystemFields_Call) Return(content1 *content.Content, err error) *MockContentServiceInterface_SetSystemFields_Call
- func (_c *MockContentServiceInterface_SetSystemFields_Call) Run(run func(ctx context.Context, contentID int, principal kernel.Principal, ...)) *MockContentServiceInterface_SetSystemFields_Call
- func (_c *MockContentServiceInterface_SetSystemFields_Call) RunAndReturn(...) *MockContentServiceInterface_SetSystemFields_Call
- type MockContentServiceInterface_Update_Call
- func (_c *MockContentServiceInterface_Update_Call) Return(content1 *content.Content, err error) *MockContentServiceInterface_Update_Call
- func (_c *MockContentServiceInterface_Update_Call) Run(run func(ctx context.Context, id int, principal kernel.Principal, ...)) *MockContentServiceInterface_Update_Call
- func (_c *MockContentServiceInterface_Update_Call) RunAndReturn(...) *MockContentServiceInterface_Update_Call
- type MockDashboardServiceInterface
- type MockDashboardServiceInterface_Expecter
- type MockDashboardServiceInterface_GetStats_Call
- func (_c *MockDashboardServiceInterface_GetStats_Call) Return(stats *dashboard.Stats, err error) *MockDashboardServiceInterface_GetStats_Call
- func (_c *MockDashboardServiceInterface_GetStats_Call) Run(run func(ctx context.Context, principal kernel.Principal)) *MockDashboardServiceInterface_GetStats_Call
- func (_c *MockDashboardServiceInterface_GetStats_Call) RunAndReturn(...) *MockDashboardServiceInterface_GetStats_Call
- type MockPostTypeLister
- type MockPostTypeLister_Expecter
- type MockPostTypeLister_GetAll_Call
- func (_c *MockPostTypeLister_GetAll_Call) Return(postTypes []posttype.PostType) *MockPostTypeLister_GetAll_Call
- func (_c *MockPostTypeLister_GetAll_Call) Run(run func()) *MockPostTypeLister_GetAll_Call
- func (_c *MockPostTypeLister_GetAll_Call) RunAndReturn(run func() []posttype.PostType) *MockPostTypeLister_GetAll_Call
- type MockPublicFieldLookup
- type MockPublicFieldLookup_Expecter
- type MockPublicFieldLookup_ExposedFields_Call
- func (_c *MockPublicFieldLookup_ExposedFields_Call) Return(strings []string) *MockPublicFieldLookup_ExposedFields_Call
- func (_c *MockPublicFieldLookup_ExposedFields_Call) Run(run func(resource string, postType string)) *MockPublicFieldLookup_ExposedFields_Call
- func (_c *MockPublicFieldLookup_ExposedFields_Call) RunAndReturn(run func(resource string, postType string) []string) *MockPublicFieldLookup_ExposedFields_Call
- type MockPublicFieldLookup_IsQueryable_Call
- func (_c *MockPublicFieldLookup_IsQueryable_Call) Return(b bool) *MockPublicFieldLookup_IsQueryable_Call
- func (_c *MockPublicFieldLookup_IsQueryable_Call) Run(run func(resource string, postType string, field string, operation string)) *MockPublicFieldLookup_IsQueryable_Call
- func (_c *MockPublicFieldLookup_IsQueryable_Call) RunAndReturn(...) *MockPublicFieldLookup_IsQueryable_Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockAPIKeyService ¶
MockAPIKeyService is an autogenerated mock type for the APIKeyService type
func NewMockAPIKeyService ¶
func NewMockAPIKeyService(t interface {
mock.TestingT
Cleanup(func())
}) *MockAPIKeyService
NewMockAPIKeyService creates a new instance of MockAPIKeyService. 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 (*MockAPIKeyService) Create ¶
func (_mock *MockAPIKeyService) Create(ctx context.Context, principal kernel.Principal, name string) (string, *apikey.APIKey, error)
Create provides a mock function for the type MockAPIKeyService
func (*MockAPIKeyService) EXPECT ¶
func (_m *MockAPIKeyService) EXPECT() *MockAPIKeyService_Expecter
type MockAPIKeyService_Create_Call ¶
MockAPIKeyService_Create_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Create'
func (*MockAPIKeyService_Create_Call) Return ¶
func (_c *MockAPIKeyService_Create_Call) Return(s string, aPIKey *apikey.APIKey, err error) *MockAPIKeyService_Create_Call
func (*MockAPIKeyService_Create_Call) Run ¶
func (_c *MockAPIKeyService_Create_Call) Run(run func(ctx context.Context, principal kernel.Principal, name string)) *MockAPIKeyService_Create_Call
func (*MockAPIKeyService_Create_Call) RunAndReturn ¶
type MockAPIKeyService_Expecter ¶
type MockAPIKeyService_Expecter struct {
// contains filtered or unexported fields
}
func (*MockAPIKeyService_Expecter) Create ¶
func (_e *MockAPIKeyService_Expecter) Create(ctx any, principal any, name any) *MockAPIKeyService_Create_Call
Create is a helper method to define mock.On call
- ctx context.Context
- principal kernel.Principal
- name string
func (*MockAPIKeyService_Expecter) List ¶
func (_e *MockAPIKeyService_Expecter) List(ctx any, principal any) *MockAPIKeyService_List_Call
List is a helper method to define mock.On call
- ctx context.Context
- principal kernel.Principal
func (*MockAPIKeyService_Expecter) Revoke ¶
func (_e *MockAPIKeyService_Expecter) Revoke(ctx any, id any, principal any) *MockAPIKeyService_Revoke_Call
Revoke is a helper method to define mock.On call
- ctx context.Context
- id int
- principal kernel.Principal
type MockAPIKeyService_List_Call ¶
MockAPIKeyService_List_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'List'
func (*MockAPIKeyService_List_Call) Return ¶
func (_c *MockAPIKeyService_List_Call) Return(aPIKeys []*apikey.APIKey, err error) *MockAPIKeyService_List_Call
func (*MockAPIKeyService_List_Call) Run ¶
func (_c *MockAPIKeyService_List_Call) Run(run func(ctx context.Context, principal kernel.Principal)) *MockAPIKeyService_List_Call
func (*MockAPIKeyService_List_Call) RunAndReturn ¶
func (_c *MockAPIKeyService_List_Call) RunAndReturn(run func(ctx context.Context, principal kernel.Principal) ([]*apikey.APIKey, error)) *MockAPIKeyService_List_Call
type MockAPIKeyService_Revoke_Call ¶
MockAPIKeyService_Revoke_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Revoke'
func (*MockAPIKeyService_Revoke_Call) Return ¶
func (_c *MockAPIKeyService_Revoke_Call) Return(aPIKey *apikey.APIKey, err error) *MockAPIKeyService_Revoke_Call
func (*MockAPIKeyService_Revoke_Call) Run ¶
func (_c *MockAPIKeyService_Revoke_Call) Run(run func(ctx context.Context, id int, principal kernel.Principal)) *MockAPIKeyService_Revoke_Call
func (*MockAPIKeyService_Revoke_Call) RunAndReturn ¶
func (_c *MockAPIKeyService_Revoke_Call) RunAndReturn(run func(ctx context.Context, id int, principal kernel.Principal) (*apikey.APIKey, error)) *MockAPIKeyService_Revoke_Call
type MockContentServiceInterface ¶
MockContentServiceInterface is an autogenerated mock type for the ContentServiceInterface type
func NewMockContentServiceInterface ¶
func NewMockContentServiceInterface(t interface {
mock.TestingT
Cleanup(func())
}) *MockContentServiceInterface
NewMockContentServiceInterface creates a new instance of MockContentServiceInterface. 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 (*MockContentServiceInterface) AuthorExists ¶
func (_mock *MockContentServiceInterface) AuthorExists(ctx context.Context, username string) (bool, error)
AuthorExists provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) Count ¶ added in v0.8.0
func (_mock *MockContentServiceInterface) Count(ctx context.Context, userID int, filters content.ContentFilters) (int, error)
Count provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) Create ¶
func (_mock *MockContentServiceInterface) Create(ctx context.Context, principal kernel.Principal, req content.CreateContentRequest) (*content.Content, error)
Create provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) DeleteContent ¶
func (_mock *MockContentServiceInterface) DeleteContent(ctx context.Context, id int, principal kernel.Principal) error
DeleteContent provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) EXPECT ¶
func (_m *MockContentServiceInterface) EXPECT() *MockContentServiceInterface_Expecter
func (*MockContentServiceInterface) GenerateSlugFromTitle ¶
func (_mock *MockContentServiceInterface) GenerateSlugFromTitle(ctx context.Context, title string) (string, error)
GenerateSlugFromTitle provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) GetAll ¶
func (_mock *MockContentServiceInterface) GetAll(ctx context.Context, limit int, offset int) ([]*content.Content, error)
GetAll provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) GetByID ¶
func (_mock *MockContentServiceInterface) GetByID(ctx context.Context, id int) (*content.Content, error)
GetByID provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) GetByUser ¶
func (_mock *MockContentServiceInterface) GetByUser(ctx context.Context, userID int, limit int, offset int) ([]*content.Content, error)
GetByUser provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) GetPublished ¶
func (_mock *MockContentServiceInterface) GetPublished(ctx context.Context, limit int, offset int) ([]*content.Content, error)
GetPublished provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) GetPublishedArchive ¶ added in v0.6.0
func (_mock *MockContentServiceInterface) GetPublishedArchive(ctx context.Context, postType string, languages []string) ([]*content.ArchiveMonth, error)
GetPublishedArchive provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) GetPublishedAuthor ¶ added in v0.7.0
func (_mock *MockContentServiceInterface) GetPublishedAuthor(ctx context.Context, username string) (*content.PublishedAuthor, error)
GetPublishedAuthor provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) GetPublishedAuthors ¶ added in v0.5.0
func (_mock *MockContentServiceInterface) GetPublishedAuthors(ctx context.Context, filters content.PublishedAuthorFilters) ([]*content.PublishedAuthor, error)
GetPublishedAuthors provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) GetPublishedByAuthorUsername ¶
func (_mock *MockContentServiceInterface) GetPublishedByAuthorUsername(ctx context.Context, username string, languages []string, limit int, offset int) ([]*content.Content, error)
GetPublishedByAuthorUsername provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) GetPublishedByPostType ¶ added in v0.6.0
func (_mock *MockContentServiceInterface) GetPublishedByPostType(ctx context.Context, postType string, languages []string, year int, month int, limit int, offset int) ([]*content.Content, error)
GetPublishedByPostType provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) GetPublishedBySlug ¶
func (_mock *MockContentServiceInterface) GetPublishedBySlug(ctx context.Context, slug string, language string) (*content.Content, error)
GetPublishedBySlug provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) GetTranslations ¶
func (_mock *MockContentServiceInterface) GetTranslations(ctx context.Context, translationGroupID int, excludeID int) ([]*content.Content, error)
GetTranslations provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) ListByFilters ¶
func (_mock *MockContentServiceInterface) ListByFilters(ctx context.Context, userID int, filters content.ContentFilters) ([]*content.Content, error)
ListByFilters provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) SearchPublished ¶
func (_mock *MockContentServiceInterface) SearchPublished(ctx context.Context, query string, limit int) ([]*content.Content, error)
SearchPublished provides a mock function for the type MockContentServiceInterface
func (*MockContentServiceInterface) SetSystemFields ¶
func (_mock *MockContentServiceInterface) SetSystemFields(ctx context.Context, contentID int, principal kernel.Principal, systemFields map[string]any) (*content.Content, error)
SetSystemFields provides a mock function for the type MockContentServiceInterface
type MockContentServiceInterface_AuthorExists_Call ¶
MockContentServiceInterface_AuthorExists_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'AuthorExists'
func (*MockContentServiceInterface_AuthorExists_Call) Return ¶
func (_c *MockContentServiceInterface_AuthorExists_Call) Return(b bool, err error) *MockContentServiceInterface_AuthorExists_Call
func (*MockContentServiceInterface_AuthorExists_Call) Run ¶
func (_c *MockContentServiceInterface_AuthorExists_Call) Run(run func(ctx context.Context, username string)) *MockContentServiceInterface_AuthorExists_Call
func (*MockContentServiceInterface_AuthorExists_Call) RunAndReturn ¶
func (_c *MockContentServiceInterface_AuthorExists_Call) RunAndReturn(run func(ctx context.Context, username string) (bool, error)) *MockContentServiceInterface_AuthorExists_Call
type MockContentServiceInterface_Count_Call ¶ added in v0.8.0
MockContentServiceInterface_Count_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Count'
func (*MockContentServiceInterface_Count_Call) Return ¶ added in v0.8.0
func (_c *MockContentServiceInterface_Count_Call) Return(n int, err error) *MockContentServiceInterface_Count_Call
func (*MockContentServiceInterface_Count_Call) Run ¶ added in v0.8.0
func (_c *MockContentServiceInterface_Count_Call) Run(run func(ctx context.Context, userID int, filters content.ContentFilters)) *MockContentServiceInterface_Count_Call
func (*MockContentServiceInterface_Count_Call) RunAndReturn ¶ added in v0.8.0
func (_c *MockContentServiceInterface_Count_Call) RunAndReturn(run func(ctx context.Context, userID int, filters content.ContentFilters) (int, error)) *MockContentServiceInterface_Count_Call
type MockContentServiceInterface_Create_Call ¶
MockContentServiceInterface_Create_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Create'
func (*MockContentServiceInterface_Create_Call) Return ¶
func (_c *MockContentServiceInterface_Create_Call) Return(content1 *content.Content, err error) *MockContentServiceInterface_Create_Call
func (*MockContentServiceInterface_Create_Call) Run ¶
func (_c *MockContentServiceInterface_Create_Call) Run(run func(ctx context.Context, principal kernel.Principal, req content.CreateContentRequest)) *MockContentServiceInterface_Create_Call
func (*MockContentServiceInterface_Create_Call) RunAndReturn ¶
func (_c *MockContentServiceInterface_Create_Call) RunAndReturn(run func(ctx context.Context, principal kernel.Principal, req content.CreateContentRequest) (*content.Content, error)) *MockContentServiceInterface_Create_Call
type MockContentServiceInterface_DeleteContent_Call ¶
MockContentServiceInterface_DeleteContent_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DeleteContent'
func (*MockContentServiceInterface_DeleteContent_Call) Return ¶
func (_c *MockContentServiceInterface_DeleteContent_Call) Return(err error) *MockContentServiceInterface_DeleteContent_Call
func (*MockContentServiceInterface_DeleteContent_Call) Run ¶
func (_c *MockContentServiceInterface_DeleteContent_Call) Run(run func(ctx context.Context, id int, principal kernel.Principal)) *MockContentServiceInterface_DeleteContent_Call
func (*MockContentServiceInterface_DeleteContent_Call) RunAndReturn ¶
func (_c *MockContentServiceInterface_DeleteContent_Call) RunAndReturn(run func(ctx context.Context, id int, principal kernel.Principal) error) *MockContentServiceInterface_DeleteContent_Call
type MockContentServiceInterface_Expecter ¶
type MockContentServiceInterface_Expecter struct {
// contains filtered or unexported fields
}
func (*MockContentServiceInterface_Expecter) AuthorExists ¶
func (_e *MockContentServiceInterface_Expecter) AuthorExists(ctx any, username any) *MockContentServiceInterface_AuthorExists_Call
AuthorExists is a helper method to define mock.On call
- ctx context.Context
- username string
func (*MockContentServiceInterface_Expecter) Count ¶ added in v0.8.0
func (_e *MockContentServiceInterface_Expecter) Count(ctx any, userID any, filters any) *MockContentServiceInterface_Count_Call
Count is a helper method to define mock.On call
- ctx context.Context
- userID int
- filters content.ContentFilters
func (*MockContentServiceInterface_Expecter) Create ¶
func (_e *MockContentServiceInterface_Expecter) Create(ctx any, principal any, req any) *MockContentServiceInterface_Create_Call
Create is a helper method to define mock.On call
- ctx context.Context
- principal kernel.Principal
- req content.CreateContentRequest
func (*MockContentServiceInterface_Expecter) DeleteContent ¶
func (_e *MockContentServiceInterface_Expecter) DeleteContent(ctx any, id any, principal any) *MockContentServiceInterface_DeleteContent_Call
DeleteContent is a helper method to define mock.On call
- ctx context.Context
- id int
- principal kernel.Principal
func (*MockContentServiceInterface_Expecter) GenerateSlugFromTitle ¶
func (_e *MockContentServiceInterface_Expecter) GenerateSlugFromTitle(ctx any, title any) *MockContentServiceInterface_GenerateSlugFromTitle_Call
GenerateSlugFromTitle is a helper method to define mock.On call
- ctx context.Context
- title string
func (*MockContentServiceInterface_Expecter) GetAll ¶
func (_e *MockContentServiceInterface_Expecter) GetAll(ctx any, limit any, offset any) *MockContentServiceInterface_GetAll_Call
GetAll is a helper method to define mock.On call
- ctx context.Context
- limit int
- offset int
func (*MockContentServiceInterface_Expecter) GetByID ¶
func (_e *MockContentServiceInterface_Expecter) GetByID(ctx any, id any) *MockContentServiceInterface_GetByID_Call
GetByID is a helper method to define mock.On call
- ctx context.Context
- id int
func (*MockContentServiceInterface_Expecter) GetByUser ¶
func (_e *MockContentServiceInterface_Expecter) GetByUser(ctx any, userID any, limit any, offset any) *MockContentServiceInterface_GetByUser_Call
GetByUser is a helper method to define mock.On call
- ctx context.Context
- userID int
- limit int
- offset int
func (*MockContentServiceInterface_Expecter) GetPublished ¶
func (_e *MockContentServiceInterface_Expecter) GetPublished(ctx any, limit any, offset any) *MockContentServiceInterface_GetPublished_Call
GetPublished is a helper method to define mock.On call
- ctx context.Context
- limit int
- offset int
func (*MockContentServiceInterface_Expecter) GetPublishedArchive ¶ added in v0.6.0
func (_e *MockContentServiceInterface_Expecter) GetPublishedArchive(ctx any, postType any, languages any) *MockContentServiceInterface_GetPublishedArchive_Call
GetPublishedArchive is a helper method to define mock.On call
- ctx context.Context
- postType string
- languages []string
func (*MockContentServiceInterface_Expecter) GetPublishedAuthor ¶ added in v0.7.0
func (_e *MockContentServiceInterface_Expecter) GetPublishedAuthor(ctx any, username any) *MockContentServiceInterface_GetPublishedAuthor_Call
GetPublishedAuthor is a helper method to define mock.On call
- ctx context.Context
- username string
func (*MockContentServiceInterface_Expecter) GetPublishedAuthors ¶ added in v0.5.0
func (_e *MockContentServiceInterface_Expecter) GetPublishedAuthors(ctx any, filters any) *MockContentServiceInterface_GetPublishedAuthors_Call
GetPublishedAuthors is a helper method to define mock.On call
- ctx context.Context
- filters content.PublishedAuthorFilters
func (*MockContentServiceInterface_Expecter) GetPublishedByAuthorUsername ¶
func (_e *MockContentServiceInterface_Expecter) GetPublishedByAuthorUsername(ctx any, username any, languages any, limit any, offset any) *MockContentServiceInterface_GetPublishedByAuthorUsername_Call
GetPublishedByAuthorUsername is a helper method to define mock.On call
- ctx context.Context
- username string
- languages []string
- limit int
- offset int
func (*MockContentServiceInterface_Expecter) GetPublishedByPostType ¶ added in v0.6.0
func (_e *MockContentServiceInterface_Expecter) GetPublishedByPostType(ctx any, postType any, languages any, year any, month any, limit any, offset any) *MockContentServiceInterface_GetPublishedByPostType_Call
GetPublishedByPostType is a helper method to define mock.On call
- ctx context.Context
- postType string
- languages []string
- year int
- month int
- limit int
- offset int
func (*MockContentServiceInterface_Expecter) GetPublishedBySlug ¶
func (_e *MockContentServiceInterface_Expecter) GetPublishedBySlug(ctx any, slug any, language any) *MockContentServiceInterface_GetPublishedBySlug_Call
GetPublishedBySlug is a helper method to define mock.On call
- ctx context.Context
- slug string
- language string
func (*MockContentServiceInterface_Expecter) GetTranslations ¶
func (_e *MockContentServiceInterface_Expecter) GetTranslations(ctx any, translationGroupID any, excludeID any) *MockContentServiceInterface_GetTranslations_Call
GetTranslations is a helper method to define mock.On call
- ctx context.Context
- translationGroupID int
- excludeID int
func (*MockContentServiceInterface_Expecter) ListByFilters ¶
func (_e *MockContentServiceInterface_Expecter) ListByFilters(ctx any, userID any, filters any) *MockContentServiceInterface_ListByFilters_Call
ListByFilters is a helper method to define mock.On call
- ctx context.Context
- userID int
- filters content.ContentFilters
func (*MockContentServiceInterface_Expecter) SearchPublished ¶
func (_e *MockContentServiceInterface_Expecter) SearchPublished(ctx any, query any, limit any) *MockContentServiceInterface_SearchPublished_Call
SearchPublished is a helper method to define mock.On call
- ctx context.Context
- query string
- limit int
func (*MockContentServiceInterface_Expecter) SetSystemFields ¶
func (_e *MockContentServiceInterface_Expecter) SetSystemFields(ctx any, contentID any, principal any, systemFields any) *MockContentServiceInterface_SetSystemFields_Call
SetSystemFields is a helper method to define mock.On call
- ctx context.Context
- contentID int
- principal kernel.Principal
- systemFields map[string]any
func (*MockContentServiceInterface_Expecter) Update ¶
func (_e *MockContentServiceInterface_Expecter) Update(ctx any, id any, principal any, req any) *MockContentServiceInterface_Update_Call
Update is a helper method to define mock.On call
- ctx context.Context
- id int
- principal kernel.Principal
- req content0.UpdateContentRequest
type MockContentServiceInterface_GenerateSlugFromTitle_Call ¶
MockContentServiceInterface_GenerateSlugFromTitle_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GenerateSlugFromTitle'
func (*MockContentServiceInterface_GenerateSlugFromTitle_Call) Return ¶
func (_c *MockContentServiceInterface_GenerateSlugFromTitle_Call) Return(s string, err error) *MockContentServiceInterface_GenerateSlugFromTitle_Call
func (*MockContentServiceInterface_GenerateSlugFromTitle_Call) Run ¶
func (_c *MockContentServiceInterface_GenerateSlugFromTitle_Call) Run(run func(ctx context.Context, title string)) *MockContentServiceInterface_GenerateSlugFromTitle_Call
func (*MockContentServiceInterface_GenerateSlugFromTitle_Call) RunAndReturn ¶
func (_c *MockContentServiceInterface_GenerateSlugFromTitle_Call) RunAndReturn(run func(ctx context.Context, title string) (string, error)) *MockContentServiceInterface_GenerateSlugFromTitle_Call
type MockContentServiceInterface_GetAll_Call ¶
MockContentServiceInterface_GetAll_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetAll'
func (*MockContentServiceInterface_GetAll_Call) Return ¶
func (_c *MockContentServiceInterface_GetAll_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_GetAll_Call
func (*MockContentServiceInterface_GetAll_Call) Run ¶
func (_c *MockContentServiceInterface_GetAll_Call) Run(run func(ctx context.Context, limit int, offset int)) *MockContentServiceInterface_GetAll_Call
func (*MockContentServiceInterface_GetAll_Call) RunAndReturn ¶
func (_c *MockContentServiceInterface_GetAll_Call) RunAndReturn(run func(ctx context.Context, limit int, offset int) ([]*content.Content, error)) *MockContentServiceInterface_GetAll_Call
type MockContentServiceInterface_GetByID_Call ¶
MockContentServiceInterface_GetByID_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetByID'
func (*MockContentServiceInterface_GetByID_Call) Return ¶
func (_c *MockContentServiceInterface_GetByID_Call) Return(content1 *content.Content, err error) *MockContentServiceInterface_GetByID_Call
func (*MockContentServiceInterface_GetByID_Call) Run ¶
func (_c *MockContentServiceInterface_GetByID_Call) Run(run func(ctx context.Context, id int)) *MockContentServiceInterface_GetByID_Call
func (*MockContentServiceInterface_GetByID_Call) RunAndReturn ¶
func (_c *MockContentServiceInterface_GetByID_Call) RunAndReturn(run func(ctx context.Context, id int) (*content.Content, error)) *MockContentServiceInterface_GetByID_Call
type MockContentServiceInterface_GetByUser_Call ¶
MockContentServiceInterface_GetByUser_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetByUser'
func (*MockContentServiceInterface_GetByUser_Call) Return ¶
func (_c *MockContentServiceInterface_GetByUser_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_GetByUser_Call
func (*MockContentServiceInterface_GetByUser_Call) Run ¶
func (_c *MockContentServiceInterface_GetByUser_Call) Run(run func(ctx context.Context, userID int, limit int, offset int)) *MockContentServiceInterface_GetByUser_Call
func (*MockContentServiceInterface_GetByUser_Call) RunAndReturn ¶
func (_c *MockContentServiceInterface_GetByUser_Call) RunAndReturn(run func(ctx context.Context, userID int, limit int, offset int) ([]*content.Content, error)) *MockContentServiceInterface_GetByUser_Call
type MockContentServiceInterface_GetPublishedArchive_Call ¶ added in v0.6.0
MockContentServiceInterface_GetPublishedArchive_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetPublishedArchive'
func (*MockContentServiceInterface_GetPublishedArchive_Call) Return ¶ added in v0.6.0
func (_c *MockContentServiceInterface_GetPublishedArchive_Call) Return(archiveMonths []*content.ArchiveMonth, err error) *MockContentServiceInterface_GetPublishedArchive_Call
func (*MockContentServiceInterface_GetPublishedArchive_Call) Run ¶ added in v0.6.0
func (_c *MockContentServiceInterface_GetPublishedArchive_Call) Run(run func(ctx context.Context, postType string, languages []string)) *MockContentServiceInterface_GetPublishedArchive_Call
func (*MockContentServiceInterface_GetPublishedArchive_Call) RunAndReturn ¶ added in v0.6.0
func (_c *MockContentServiceInterface_GetPublishedArchive_Call) RunAndReturn(run func(ctx context.Context, postType string, languages []string) ([]*content.ArchiveMonth, error)) *MockContentServiceInterface_GetPublishedArchive_Call
type MockContentServiceInterface_GetPublishedAuthor_Call ¶ added in v0.7.0
MockContentServiceInterface_GetPublishedAuthor_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetPublishedAuthor'
func (*MockContentServiceInterface_GetPublishedAuthor_Call) Return ¶ added in v0.7.0
func (_c *MockContentServiceInterface_GetPublishedAuthor_Call) Return(publishedAuthor *content.PublishedAuthor, err error) *MockContentServiceInterface_GetPublishedAuthor_Call
func (*MockContentServiceInterface_GetPublishedAuthor_Call) Run ¶ added in v0.7.0
func (_c *MockContentServiceInterface_GetPublishedAuthor_Call) Run(run func(ctx context.Context, username string)) *MockContentServiceInterface_GetPublishedAuthor_Call
func (*MockContentServiceInterface_GetPublishedAuthor_Call) RunAndReturn ¶ added in v0.7.0
func (_c *MockContentServiceInterface_GetPublishedAuthor_Call) RunAndReturn(run func(ctx context.Context, username string) (*content.PublishedAuthor, error)) *MockContentServiceInterface_GetPublishedAuthor_Call
type MockContentServiceInterface_GetPublishedAuthors_Call ¶ added in v0.5.0
MockContentServiceInterface_GetPublishedAuthors_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetPublishedAuthors'
func (*MockContentServiceInterface_GetPublishedAuthors_Call) Return ¶ added in v0.5.0
func (_c *MockContentServiceInterface_GetPublishedAuthors_Call) Return(publishedAuthors []*content.PublishedAuthor, err error) *MockContentServiceInterface_GetPublishedAuthors_Call
func (*MockContentServiceInterface_GetPublishedAuthors_Call) Run ¶ added in v0.5.0
func (_c *MockContentServiceInterface_GetPublishedAuthors_Call) Run(run func(ctx context.Context, filters content.PublishedAuthorFilters)) *MockContentServiceInterface_GetPublishedAuthors_Call
func (*MockContentServiceInterface_GetPublishedAuthors_Call) RunAndReturn ¶ added in v0.5.0
func (_c *MockContentServiceInterface_GetPublishedAuthors_Call) RunAndReturn(run func(ctx context.Context, filters content.PublishedAuthorFilters) ([]*content.PublishedAuthor, error)) *MockContentServiceInterface_GetPublishedAuthors_Call
type MockContentServiceInterface_GetPublishedByAuthorUsername_Call ¶
MockContentServiceInterface_GetPublishedByAuthorUsername_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetPublishedByAuthorUsername'
func (*MockContentServiceInterface_GetPublishedByAuthorUsername_Call) Return ¶
func (_c *MockContentServiceInterface_GetPublishedByAuthorUsername_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_GetPublishedByAuthorUsername_Call
func (*MockContentServiceInterface_GetPublishedByAuthorUsername_Call) Run ¶
func (_c *MockContentServiceInterface_GetPublishedByAuthorUsername_Call) Run(run func(ctx context.Context, username string, languages []string, limit int, offset int)) *MockContentServiceInterface_GetPublishedByAuthorUsername_Call
func (*MockContentServiceInterface_GetPublishedByAuthorUsername_Call) RunAndReturn ¶
type MockContentServiceInterface_GetPublishedByPostType_Call ¶ added in v0.6.0
MockContentServiceInterface_GetPublishedByPostType_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetPublishedByPostType'
func (*MockContentServiceInterface_GetPublishedByPostType_Call) Return ¶ added in v0.6.0
func (_c *MockContentServiceInterface_GetPublishedByPostType_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_GetPublishedByPostType_Call
func (*MockContentServiceInterface_GetPublishedByPostType_Call) Run ¶ added in v0.6.0
func (_c *MockContentServiceInterface_GetPublishedByPostType_Call) Run(run func(ctx context.Context, postType string, languages []string, year int, month int, limit int, offset int)) *MockContentServiceInterface_GetPublishedByPostType_Call
func (*MockContentServiceInterface_GetPublishedByPostType_Call) RunAndReturn ¶ added in v0.6.0
type MockContentServiceInterface_GetPublishedBySlug_Call ¶
MockContentServiceInterface_GetPublishedBySlug_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetPublishedBySlug'
func (*MockContentServiceInterface_GetPublishedBySlug_Call) Return ¶
func (_c *MockContentServiceInterface_GetPublishedBySlug_Call) Return(content1 *content.Content, err error) *MockContentServiceInterface_GetPublishedBySlug_Call
func (*MockContentServiceInterface_GetPublishedBySlug_Call) Run ¶
func (_c *MockContentServiceInterface_GetPublishedBySlug_Call) Run(run func(ctx context.Context, slug string, language string)) *MockContentServiceInterface_GetPublishedBySlug_Call
func (*MockContentServiceInterface_GetPublishedBySlug_Call) RunAndReturn ¶
func (_c *MockContentServiceInterface_GetPublishedBySlug_Call) RunAndReturn(run func(ctx context.Context, slug string, language string) (*content.Content, error)) *MockContentServiceInterface_GetPublishedBySlug_Call
type MockContentServiceInterface_GetPublished_Call ¶
MockContentServiceInterface_GetPublished_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetPublished'
func (*MockContentServiceInterface_GetPublished_Call) Return ¶
func (_c *MockContentServiceInterface_GetPublished_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_GetPublished_Call
func (*MockContentServiceInterface_GetPublished_Call) Run ¶
func (_c *MockContentServiceInterface_GetPublished_Call) Run(run func(ctx context.Context, limit int, offset int)) *MockContentServiceInterface_GetPublished_Call
func (*MockContentServiceInterface_GetPublished_Call) RunAndReturn ¶
func (_c *MockContentServiceInterface_GetPublished_Call) RunAndReturn(run func(ctx context.Context, limit int, offset int) ([]*content.Content, error)) *MockContentServiceInterface_GetPublished_Call
type MockContentServiceInterface_GetTranslations_Call ¶
MockContentServiceInterface_GetTranslations_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetTranslations'
func (*MockContentServiceInterface_GetTranslations_Call) Return ¶
func (_c *MockContentServiceInterface_GetTranslations_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_GetTranslations_Call
func (*MockContentServiceInterface_GetTranslations_Call) Run ¶
func (_c *MockContentServiceInterface_GetTranslations_Call) Run(run func(ctx context.Context, translationGroupID int, excludeID int)) *MockContentServiceInterface_GetTranslations_Call
func (*MockContentServiceInterface_GetTranslations_Call) RunAndReturn ¶
func (_c *MockContentServiceInterface_GetTranslations_Call) RunAndReturn(run func(ctx context.Context, translationGroupID int, excludeID int) ([]*content.Content, error)) *MockContentServiceInterface_GetTranslations_Call
type MockContentServiceInterface_ListByFilters_Call ¶
MockContentServiceInterface_ListByFilters_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListByFilters'
func (*MockContentServiceInterface_ListByFilters_Call) Return ¶
func (_c *MockContentServiceInterface_ListByFilters_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_ListByFilters_Call
func (*MockContentServiceInterface_ListByFilters_Call) Run ¶
func (_c *MockContentServiceInterface_ListByFilters_Call) Run(run func(ctx context.Context, userID int, filters content.ContentFilters)) *MockContentServiceInterface_ListByFilters_Call
func (*MockContentServiceInterface_ListByFilters_Call) RunAndReturn ¶
func (_c *MockContentServiceInterface_ListByFilters_Call) RunAndReturn(run func(ctx context.Context, userID int, filters content.ContentFilters) ([]*content.Content, error)) *MockContentServiceInterface_ListByFilters_Call
type MockContentServiceInterface_SearchPublished_Call ¶
MockContentServiceInterface_SearchPublished_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SearchPublished'
func (*MockContentServiceInterface_SearchPublished_Call) Return ¶
func (_c *MockContentServiceInterface_SearchPublished_Call) Return(contents []*content.Content, err error) *MockContentServiceInterface_SearchPublished_Call
func (*MockContentServiceInterface_SearchPublished_Call) Run ¶
func (_c *MockContentServiceInterface_SearchPublished_Call) Run(run func(ctx context.Context, query string, limit int)) *MockContentServiceInterface_SearchPublished_Call
func (*MockContentServiceInterface_SearchPublished_Call) RunAndReturn ¶
func (_c *MockContentServiceInterface_SearchPublished_Call) RunAndReturn(run func(ctx context.Context, query string, limit int) ([]*content.Content, error)) *MockContentServiceInterface_SearchPublished_Call
type MockContentServiceInterface_SetSystemFields_Call ¶
MockContentServiceInterface_SetSystemFields_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SetSystemFields'
func (*MockContentServiceInterface_SetSystemFields_Call) Return ¶
func (_c *MockContentServiceInterface_SetSystemFields_Call) Return(content1 *content.Content, err error) *MockContentServiceInterface_SetSystemFields_Call
func (*MockContentServiceInterface_SetSystemFields_Call) Run ¶
func (_c *MockContentServiceInterface_SetSystemFields_Call) Run(run func(ctx context.Context, contentID int, principal kernel.Principal, systemFields map[string]any)) *MockContentServiceInterface_SetSystemFields_Call
func (*MockContentServiceInterface_SetSystemFields_Call) RunAndReturn ¶
type MockContentServiceInterface_Update_Call ¶
MockContentServiceInterface_Update_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Update'
func (*MockContentServiceInterface_Update_Call) Return ¶
func (_c *MockContentServiceInterface_Update_Call) Return(content1 *content.Content, err error) *MockContentServiceInterface_Update_Call
func (*MockContentServiceInterface_Update_Call) Run ¶
func (_c *MockContentServiceInterface_Update_Call) Run(run func(ctx context.Context, id int, principal kernel.Principal, req content0.UpdateContentRequest)) *MockContentServiceInterface_Update_Call
func (*MockContentServiceInterface_Update_Call) RunAndReturn ¶
func (_c *MockContentServiceInterface_Update_Call) RunAndReturn(run func(ctx context.Context, id int, principal kernel.Principal, req content0.UpdateContentRequest) (*content.Content, error)) *MockContentServiceInterface_Update_Call
type MockDashboardServiceInterface ¶
MockDashboardServiceInterface is an autogenerated mock type for the DashboardServiceInterface type
func NewMockDashboardServiceInterface ¶
func NewMockDashboardServiceInterface(t interface {
mock.TestingT
Cleanup(func())
}) *MockDashboardServiceInterface
NewMockDashboardServiceInterface creates a new instance of MockDashboardServiceInterface. 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 (*MockDashboardServiceInterface) EXPECT ¶
func (_m *MockDashboardServiceInterface) EXPECT() *MockDashboardServiceInterface_Expecter
type MockDashboardServiceInterface_Expecter ¶
type MockDashboardServiceInterface_Expecter struct {
// contains filtered or unexported fields
}
func (*MockDashboardServiceInterface_Expecter) GetStats ¶
func (_e *MockDashboardServiceInterface_Expecter) GetStats(ctx any, principal any) *MockDashboardServiceInterface_GetStats_Call
GetStats is a helper method to define mock.On call
- ctx context.Context
- principal kernel.Principal
type MockDashboardServiceInterface_GetStats_Call ¶
MockDashboardServiceInterface_GetStats_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetStats'
func (*MockDashboardServiceInterface_GetStats_Call) Return ¶
func (_c *MockDashboardServiceInterface_GetStats_Call) Return(stats *dashboard.Stats, err error) *MockDashboardServiceInterface_GetStats_Call
func (*MockDashboardServiceInterface_GetStats_Call) Run ¶
func (_c *MockDashboardServiceInterface_GetStats_Call) Run(run func(ctx context.Context, principal kernel.Principal)) *MockDashboardServiceInterface_GetStats_Call
func (*MockDashboardServiceInterface_GetStats_Call) RunAndReturn ¶
func (_c *MockDashboardServiceInterface_GetStats_Call) RunAndReturn(run func(ctx context.Context, principal kernel.Principal) (*dashboard.Stats, error)) *MockDashboardServiceInterface_GetStats_Call
type MockPostTypeLister ¶ added in v0.9.0
MockPostTypeLister is an autogenerated mock type for the PostTypeLister type
func NewMockPostTypeLister ¶ added in v0.9.0
func NewMockPostTypeLister(t interface {
mock.TestingT
Cleanup(func())
}) *MockPostTypeLister
NewMockPostTypeLister creates a new instance of MockPostTypeLister. 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 (*MockPostTypeLister) EXPECT ¶ added in v0.9.0
func (_m *MockPostTypeLister) EXPECT() *MockPostTypeLister_Expecter
func (*MockPostTypeLister) GetAll ¶ added in v0.9.0
func (_mock *MockPostTypeLister) GetAll() []posttype.PostType
GetAll provides a mock function for the type MockPostTypeLister
type MockPostTypeLister_Expecter ¶ added in v0.9.0
type MockPostTypeLister_Expecter struct {
// contains filtered or unexported fields
}
func (*MockPostTypeLister_Expecter) GetAll ¶ added in v0.9.0
func (_e *MockPostTypeLister_Expecter) GetAll() *MockPostTypeLister_GetAll_Call
GetAll is a helper method to define mock.On call
type MockPostTypeLister_GetAll_Call ¶ added in v0.9.0
MockPostTypeLister_GetAll_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetAll'
func (*MockPostTypeLister_GetAll_Call) Return ¶ added in v0.9.0
func (_c *MockPostTypeLister_GetAll_Call) Return(postTypes []posttype.PostType) *MockPostTypeLister_GetAll_Call
func (*MockPostTypeLister_GetAll_Call) Run ¶ added in v0.9.0
func (_c *MockPostTypeLister_GetAll_Call) Run(run func()) *MockPostTypeLister_GetAll_Call
func (*MockPostTypeLister_GetAll_Call) RunAndReturn ¶ added in v0.9.0
func (_c *MockPostTypeLister_GetAll_Call) RunAndReturn(run func() []posttype.PostType) *MockPostTypeLister_GetAll_Call
type MockPublicFieldLookup ¶ added in v0.7.0
MockPublicFieldLookup is an autogenerated mock type for the PublicFieldLookup type
func NewMockPublicFieldLookup ¶ added in v0.7.0
func NewMockPublicFieldLookup(t interface {
mock.TestingT
Cleanup(func())
}) *MockPublicFieldLookup
NewMockPublicFieldLookup creates a new instance of MockPublicFieldLookup. 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 (*MockPublicFieldLookup) EXPECT ¶ added in v0.7.0
func (_m *MockPublicFieldLookup) EXPECT() *MockPublicFieldLookup_Expecter
func (*MockPublicFieldLookup) ExposedFields ¶ added in v0.7.0
func (_mock *MockPublicFieldLookup) ExposedFields(resource string, postType string) []string
ExposedFields provides a mock function for the type MockPublicFieldLookup
func (*MockPublicFieldLookup) IsQueryable ¶ added in v0.7.0
func (_mock *MockPublicFieldLookup) IsQueryable(resource string, postType string, field string, operation string) bool
IsQueryable provides a mock function for the type MockPublicFieldLookup
type MockPublicFieldLookup_Expecter ¶ added in v0.7.0
type MockPublicFieldLookup_Expecter struct {
// contains filtered or unexported fields
}
func (*MockPublicFieldLookup_Expecter) ExposedFields ¶ added in v0.7.0
func (_e *MockPublicFieldLookup_Expecter) ExposedFields(resource any, postType any) *MockPublicFieldLookup_ExposedFields_Call
ExposedFields is a helper method to define mock.On call
- resource string
- postType string
func (*MockPublicFieldLookup_Expecter) IsQueryable ¶ added in v0.7.0
func (_e *MockPublicFieldLookup_Expecter) IsQueryable(resource any, postType any, field any, operation any) *MockPublicFieldLookup_IsQueryable_Call
IsQueryable is a helper method to define mock.On call
- resource string
- postType string
- field string
- operation string
type MockPublicFieldLookup_ExposedFields_Call ¶ added in v0.7.0
MockPublicFieldLookup_ExposedFields_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ExposedFields'
func (*MockPublicFieldLookup_ExposedFields_Call) Return ¶ added in v0.7.0
func (_c *MockPublicFieldLookup_ExposedFields_Call) Return(strings []string) *MockPublicFieldLookup_ExposedFields_Call
func (*MockPublicFieldLookup_ExposedFields_Call) Run ¶ added in v0.7.0
func (_c *MockPublicFieldLookup_ExposedFields_Call) Run(run func(resource string, postType string)) *MockPublicFieldLookup_ExposedFields_Call
func (*MockPublicFieldLookup_ExposedFields_Call) RunAndReturn ¶ added in v0.7.0
func (_c *MockPublicFieldLookup_ExposedFields_Call) RunAndReturn(run func(resource string, postType string) []string) *MockPublicFieldLookup_ExposedFields_Call
type MockPublicFieldLookup_IsQueryable_Call ¶ added in v0.7.0
MockPublicFieldLookup_IsQueryable_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'IsQueryable'
func (*MockPublicFieldLookup_IsQueryable_Call) Return ¶ added in v0.7.0
func (_c *MockPublicFieldLookup_IsQueryable_Call) Return(b bool) *MockPublicFieldLookup_IsQueryable_Call
func (*MockPublicFieldLookup_IsQueryable_Call) Run ¶ added in v0.7.0
func (_c *MockPublicFieldLookup_IsQueryable_Call) Run(run func(resource string, postType string, field string, operation string)) *MockPublicFieldLookup_IsQueryable_Call
func (*MockPublicFieldLookup_IsQueryable_Call) RunAndReturn ¶ added in v0.7.0
func (_c *MockPublicFieldLookup_IsQueryable_Call) RunAndReturn(run func(resource string, postType string, field string, operation string) bool) *MockPublicFieldLookup_IsQueryable_Call