mocks

package
v0.0.0-...-c266f6d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 24, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CrawService

type CrawService struct {
	mock.Mock
}

CrawService is an autogenerated mock type for the CrawService type

func NewCrawService

func NewCrawService(t mockConstructorTestingTNewCrawService) *CrawService

NewCrawService creates a new instance of CrawService. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*CrawService) Craw

func (_m *CrawService) Craw(_a0 context.Context, _a1 *dto.Site) error

Craw provides a mock function with given fields: _a0, _a1

func (*CrawService) EXPECT

func (_m *CrawService) EXPECT() *CrawService_Expecter

func (*CrawService) PickAgent

func (_m *CrawService) PickAgent(_a0 context.Context, _a1 *dto.Site) (*dto.Node, error)

PickAgent provides a mock function with given fields: _a0, _a1

type CrawService_Craw_Call

type CrawService_Craw_Call struct {
	*mock.Call
}

CrawService_Craw_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Craw'

func (*CrawService_Craw_Call) Return

func (*CrawService_Craw_Call) Run

func (_c *CrawService_Craw_Call) Run(run func(_a0 context.Context, _a1 *dto.Site)) *CrawService_Craw_Call

type CrawService_Expecter

type CrawService_Expecter struct {
	// contains filtered or unexported fields
}

func (*CrawService_Expecter) Craw

func (_e *CrawService_Expecter) Craw(_a0 interface{}, _a1 interface{}) *CrawService_Craw_Call

Craw is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 *dto.Site

func (*CrawService_Expecter) PickAgent

func (_e *CrawService_Expecter) PickAgent(_a0 interface{}, _a1 interface{}) *CrawService_PickAgent_Call

PickAgent is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 *dto.Site

type CrawService_PickAgent_Call

type CrawService_PickAgent_Call struct {
	*mock.Call
}

CrawService_PickAgent_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'PickAgent'

func (*CrawService_PickAgent_Call) Return

func (*CrawService_PickAgent_Call) Run

type FavorRepo

type FavorRepo struct {
	mock.Mock
}

FavorRepo is an autogenerated mock type for the FavorRepo type

func NewFavorRepo

func NewFavorRepo(t mockConstructorTestingTNewFavorRepo) *FavorRepo

NewFavorRepo creates a new instance of FavorRepo. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*FavorRepo) Create

func (_m *FavorRepo) Create(_a0 context.Context, _a1 model.Favor) error

Create provides a mock function with given fields: _a0, _a1

func (*FavorRepo) Del

func (_m *FavorRepo) Del(_a0 context.Context, _a1 model.Favor) error

Del provides a mock function with given fields: _a0, _a1

func (*FavorRepo) EXPECT

func (_m *FavorRepo) EXPECT() *FavorRepo_Expecter

func (*FavorRepo) Get

func (_m *FavorRepo) Get(_a0 context.Context, _a1 *dto.Query) ([]model.Favor, error)

Get provides a mock function with given fields: _a0, _a1

func (*FavorRepo) Sites

func (_m *FavorRepo) Sites(_a0 context.Context, _a1 *dto.Query) []string

Sites provides a mock function with given fields: _a0, _a1

type FavorRepo_Create_Call

type FavorRepo_Create_Call struct {
	*mock.Call
}

FavorRepo_Create_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Create'

func (*FavorRepo_Create_Call) Return

func (*FavorRepo_Create_Call) Run

type FavorRepo_Del_Call

type FavorRepo_Del_Call struct {
	*mock.Call
}

FavorRepo_Del_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Del'

func (*FavorRepo_Del_Call) Return

func (_c *FavorRepo_Del_Call) Return(_a0 error) *FavorRepo_Del_Call

func (*FavorRepo_Del_Call) Run

func (_c *FavorRepo_Del_Call) Run(run func(_a0 context.Context, _a1 model.Favor)) *FavorRepo_Del_Call

type FavorRepo_Expecter

type FavorRepo_Expecter struct {
	// contains filtered or unexported fields
}

func (*FavorRepo_Expecter) Create

func (_e *FavorRepo_Expecter) Create(_a0 interface{}, _a1 interface{}) *FavorRepo_Create_Call

Create is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 model.Favor

func (*FavorRepo_Expecter) Del

func (_e *FavorRepo_Expecter) Del(_a0 interface{}, _a1 interface{}) *FavorRepo_Del_Call

Del is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 model.Favor

func (*FavorRepo_Expecter) Get

func (_e *FavorRepo_Expecter) Get(_a0 interface{}, _a1 interface{}) *FavorRepo_Get_Call

Get is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 *dto.Query

func (*FavorRepo_Expecter) Sites

func (_e *FavorRepo_Expecter) Sites(_a0 interface{}, _a1 interface{}) *FavorRepo_Sites_Call

Sites is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 *dto.Query

type FavorRepo_Get_Call

type FavorRepo_Get_Call struct {
	*mock.Call
}

FavorRepo_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'

func (*FavorRepo_Get_Call) Return

func (_c *FavorRepo_Get_Call) Return(_a0 []model.Favor, _a1 error) *FavorRepo_Get_Call

func (*FavorRepo_Get_Call) Run

func (_c *FavorRepo_Get_Call) Run(run func(_a0 context.Context, _a1 *dto.Query)) *FavorRepo_Get_Call

type FavorRepo_Sites_Call

type FavorRepo_Sites_Call struct {
	*mock.Call
}

FavorRepo_Sites_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Sites'

func (*FavorRepo_Sites_Call) Return

func (*FavorRepo_Sites_Call) Run

func (_c *FavorRepo_Sites_Call) Run(run func(_a0 context.Context, _a1 *dto.Query)) *FavorRepo_Sites_Call

type FavorService

type FavorService struct {
	mock.Mock
}

FavorService is an autogenerated mock type for the FavorService type

func NewFavorService

func NewFavorService(t mockConstructorTestingTNewFavorService) *FavorService

NewFavorService creates a new instance of FavorService. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*FavorService) Add

func (_m *FavorService) Add(_a0 context.Context, _a1 *dto.Favor) error

Add provides a mock function with given fields: _a0, _a1

func (*FavorService) Del

func (_m *FavorService) Del(_a0 context.Context, _a1 int, _a2 string, _a3 string) error

Del provides a mock function with given fields: _a0, _a1, _a2, _a3

func (*FavorService) EXPECT

func (_m *FavorService) EXPECT() *FavorService_Expecter

func (*FavorService) UserFavorSites

func (_m *FavorService) UserFavorSites(_a0 context.Context, _a1 int, _a2 string) ([]string, error)

UserFavorSites provides a mock function with given fields: _a0, _a1, _a2

func (*FavorService) UserFavors

func (_m *FavorService) UserFavors(_a0 context.Context, _a1 int, _a2 string, _a3 string) ([]*dto.Favor, error)

UserFavors provides a mock function with given fields: _a0, _a1, _a2, _a3

type FavorService_Add_Call

type FavorService_Add_Call struct {
	*mock.Call
}

FavorService_Add_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Add'

func (*FavorService_Add_Call) Return

func (*FavorService_Add_Call) Run

func (_c *FavorService_Add_Call) Run(run func(_a0 context.Context, _a1 *dto.Favor)) *FavorService_Add_Call

type FavorService_Del_Call

type FavorService_Del_Call struct {
	*mock.Call
}

FavorService_Del_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Del'

func (*FavorService_Del_Call) Return

func (*FavorService_Del_Call) Run

func (_c *FavorService_Del_Call) Run(run func(_a0 context.Context, _a1 int, _a2 string, _a3 string)) *FavorService_Del_Call

type FavorService_Expecter

type FavorService_Expecter struct {
	// contains filtered or unexported fields
}

func (*FavorService_Expecter) Add

func (_e *FavorService_Expecter) Add(_a0 interface{}, _a1 interface{}) *FavorService_Add_Call

Add is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 *dto.Favor

func (*FavorService_Expecter) Del

func (_e *FavorService_Expecter) Del(_a0 interface{}, _a1 interface{}, _a2 interface{}, _a3 interface{}) *FavorService_Del_Call

Del is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 int
  • _a2 string
  • _a3 string

func (*FavorService_Expecter) UserFavorSites

func (_e *FavorService_Expecter) UserFavorSites(_a0 interface{}, _a1 interface{}, _a2 interface{}) *FavorService_UserFavorSites_Call

UserFavorSites is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 int
  • _a2 string

func (*FavorService_Expecter) UserFavors

func (_e *FavorService_Expecter) UserFavors(_a0 interface{}, _a1 interface{}, _a2 interface{}, _a3 interface{}) *FavorService_UserFavors_Call

UserFavors is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 int
  • _a2 string
  • _a3 string

type FavorService_UserFavorSites_Call

type FavorService_UserFavorSites_Call struct {
	*mock.Call
}

FavorService_UserFavorSites_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UserFavorSites'

func (*FavorService_UserFavorSites_Call) Return

func (*FavorService_UserFavorSites_Call) Run

type FavorService_UserFavors_Call

type FavorService_UserFavors_Call struct {
	*mock.Call
}

FavorService_UserFavors_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UserFavors'

func (*FavorService_UserFavors_Call) Return

func (*FavorService_UserFavors_Call) Run

type NodeRepo

type NodeRepo struct {
	mock.Mock
}

NodeRepo is an autogenerated mock type for the NodeRepo type

func NewNodeRepo

func NewNodeRepo(t mockConstructorTestingTNewNodeRepo) *NodeRepo

NewNodeRepo creates a new instance of NodeRepo. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*NodeRepo) Create

func (_m *NodeRepo) Create(_a0 context.Context, _a1 model.Node) error

Create provides a mock function with given fields: _a0, _a1

func (*NodeRepo) Del

func (_m *NodeRepo) Del(_a0 context.Context, _a1 model.Node) error

Del provides a mock function with given fields: _a0, _a1

func (*NodeRepo) EXPECT

func (_m *NodeRepo) EXPECT() *NodeRepo_Expecter

func (*NodeRepo) Get

func (_m *NodeRepo) Get(_a0 context.Context, _a1 *dto.Query) ([]model.Node, error)

Get provides a mock function with given fields: _a0, _a1

func (*NodeRepo) Update

func (_m *NodeRepo) Update(_a0 context.Context, _a1 model.Node, _a2 map[string]interface{}) error

Update provides a mock function with given fields: _a0, _a1, _a2

type NodeRepo_Create_Call

type NodeRepo_Create_Call struct {
	*mock.Call
}

NodeRepo_Create_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Create'

func (*NodeRepo_Create_Call) Return

func (*NodeRepo_Create_Call) Run

func (_c *NodeRepo_Create_Call) Run(run func(_a0 context.Context, _a1 model.Node)) *NodeRepo_Create_Call

type NodeRepo_Del_Call

type NodeRepo_Del_Call struct {
	*mock.Call
}

NodeRepo_Del_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Del'

func (*NodeRepo_Del_Call) Return

func (_c *NodeRepo_Del_Call) Return(_a0 error) *NodeRepo_Del_Call

func (*NodeRepo_Del_Call) Run

func (_c *NodeRepo_Del_Call) Run(run func(_a0 context.Context, _a1 model.Node)) *NodeRepo_Del_Call

type NodeRepo_Expecter

type NodeRepo_Expecter struct {
	// contains filtered or unexported fields
}

func (*NodeRepo_Expecter) Create

func (_e *NodeRepo_Expecter) Create(_a0 interface{}, _a1 interface{}) *NodeRepo_Create_Call

Create is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 model.Node

func (*NodeRepo_Expecter) Del

func (_e *NodeRepo_Expecter) Del(_a0 interface{}, _a1 interface{}) *NodeRepo_Del_Call

Del is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 model.Node

func (*NodeRepo_Expecter) Get

func (_e *NodeRepo_Expecter) Get(_a0 interface{}, _a1 interface{}) *NodeRepo_Get_Call

Get is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 *dto.Query

func (*NodeRepo_Expecter) Update

func (_e *NodeRepo_Expecter) Update(_a0 interface{}, _a1 interface{}, _a2 interface{}) *NodeRepo_Update_Call

Update is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 model.Node
  • _a2 map[string]interface{}

type NodeRepo_Get_Call

type NodeRepo_Get_Call struct {
	*mock.Call
}

NodeRepo_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'

func (*NodeRepo_Get_Call) Return

func (_c *NodeRepo_Get_Call) Return(_a0 []model.Node, _a1 error) *NodeRepo_Get_Call

func (*NodeRepo_Get_Call) Run

func (_c *NodeRepo_Get_Call) Run(run func(_a0 context.Context, _a1 *dto.Query)) *NodeRepo_Get_Call

type NodeRepo_Update_Call

type NodeRepo_Update_Call struct {
	*mock.Call
}

NodeRepo_Update_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Update'

func (*NodeRepo_Update_Call) Return

func (*NodeRepo_Update_Call) Run

func (_c *NodeRepo_Update_Call) Run(run func(_a0 context.Context, _a1 model.Node, _a2 map[string]interface{})) *NodeRepo_Update_Call

type NodeService

type NodeService struct {
	mock.Mock
}

NodeService is an autogenerated mock type for the NodeService type

func NewNodeService

func NewNodeService(t mockConstructorTestingTNewNodeService) *NodeService

NewNodeService creates a new instance of NodeService. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*NodeService) CheckNodes

func (_m *NodeService) CheckNodes(_a0 context.Context, _a1 *rpc.RpcPool) error

CheckNodes provides a mock function with given fields: _a0, _a1

func (*NodeService) Del

func (_m *NodeService) Del(_a0 context.Context, _a1 int) error

Del provides a mock function with given fields: _a0, _a1

func (*NodeService) EXPECT

func (_m *NodeService) EXPECT() *NodeService_Expecter

func (*NodeService) Get

func (_m *NodeService) Get(_a0 context.Context, _a1 *dto.Query) ([]*dto.Node, error)

Get provides a mock function with given fields: _a0, _a1

func (*NodeService) Upsert

func (_m *NodeService) Upsert(_a0 context.Context, _a1 *dto.Node) error

Upsert provides a mock function with given fields: _a0, _a1

type NodeService_CheckNodes_Call

type NodeService_CheckNodes_Call struct {
	*mock.Call
}

NodeService_CheckNodes_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CheckNodes'

func (*NodeService_CheckNodes_Call) Return

func (*NodeService_CheckNodes_Call) Run

type NodeService_Del_Call

type NodeService_Del_Call struct {
	*mock.Call
}

NodeService_Del_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Del'

func (*NodeService_Del_Call) Return

func (*NodeService_Del_Call) Run

func (_c *NodeService_Del_Call) Run(run func(_a0 context.Context, _a1 int)) *NodeService_Del_Call

type NodeService_Expecter

type NodeService_Expecter struct {
	// contains filtered or unexported fields
}

func (*NodeService_Expecter) CheckNodes

func (_e *NodeService_Expecter) CheckNodes(_a0 interface{}, _a1 interface{}) *NodeService_CheckNodes_Call

CheckNodes is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 *rpc.RpcPool

func (*NodeService_Expecter) Del

func (_e *NodeService_Expecter) Del(_a0 interface{}, _a1 interface{}) *NodeService_Del_Call

Del is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 int

func (*NodeService_Expecter) Get

func (_e *NodeService_Expecter) Get(_a0 interface{}, _a1 interface{}) *NodeService_Get_Call

Get is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 *dto.Query

func (*NodeService_Expecter) Upsert

func (_e *NodeService_Expecter) Upsert(_a0 interface{}, _a1 interface{}) *NodeService_Upsert_Call

Upsert is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 *dto.Node

type NodeService_Get_Call

type NodeService_Get_Call struct {
	*mock.Call
}

NodeService_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'

func (*NodeService_Get_Call) Return

func (_c *NodeService_Get_Call) Return(_a0 []*dto.Node, _a1 error) *NodeService_Get_Call

func (*NodeService_Get_Call) Run

func (_c *NodeService_Get_Call) Run(run func(_a0 context.Context, _a1 *dto.Query)) *NodeService_Get_Call

type NodeService_Upsert_Call

type NodeService_Upsert_Call struct {
	*mock.Call
}

NodeService_Upsert_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Upsert'

func (*NodeService_Upsert_Call) Return

func (*NodeService_Upsert_Call) Run

type OAuthService

type OAuthService struct {
	mock.Mock
}

OAuthService is an autogenerated mock type for the OAuthService type

func NewOAuthService

func NewOAuthService(t mockConstructorTestingTNewOAuthService) *OAuthService

NewOAuthService creates a new instance of OAuthService. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*OAuthService) Auth

func (_m *OAuthService) Auth(_a0 string, _a1 string) (oauth.User, error)

Auth provides a mock function with given fields: _a0, _a1

func (*OAuthService) EXPECT

func (_m *OAuthService) EXPECT() *OAuthService_Expecter

func (*OAuthService) GetPlatform

func (_m *OAuthService) GetPlatform(_a0 string) oauth.OAuth

GetPlatform provides a mock function with given fields: _a0

func (*OAuthService) Platforms

func (_m *OAuthService) Platforms(_a0 string) []dto.OAuthPlatform

Platforms provides a mock function with given fields: _a0

func (*OAuthService) Redirect

func (_m *OAuthService) Redirect(_a0 string) string

Redirect provides a mock function with given fields: _a0

type OAuthService_Auth_Call

type OAuthService_Auth_Call struct {
	*mock.Call
}

OAuthService_Auth_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Auth'

func (*OAuthService_Auth_Call) Return

func (*OAuthService_Auth_Call) Run

func (_c *OAuthService_Auth_Call) Run(run func(_a0 string, _a1 string)) *OAuthService_Auth_Call

type OAuthService_Expecter

type OAuthService_Expecter struct {
	// contains filtered or unexported fields
}

func (*OAuthService_Expecter) Auth

func (_e *OAuthService_Expecter) Auth(_a0 interface{}, _a1 interface{}) *OAuthService_Auth_Call

Auth is a helper method to define mock.On call

  • _a0 string
  • _a1 string

func (*OAuthService_Expecter) GetPlatform

func (_e *OAuthService_Expecter) GetPlatform(_a0 interface{}) *OAuthService_GetPlatform_Call

GetPlatform is a helper method to define mock.On call

  • _a0 string

func (*OAuthService_Expecter) Platforms

func (_e *OAuthService_Expecter) Platforms(_a0 interface{}) *OAuthService_Platforms_Call

Platforms is a helper method to define mock.On call

  • _a0 string

func (*OAuthService_Expecter) Redirect

func (_e *OAuthService_Expecter) Redirect(_a0 interface{}) *OAuthService_Redirect_Call

Redirect is a helper method to define mock.On call

  • _a0 string

type OAuthService_GetPlatform_Call

type OAuthService_GetPlatform_Call struct {
	*mock.Call
}

OAuthService_GetPlatform_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetPlatform'

func (*OAuthService_GetPlatform_Call) Return

func (*OAuthService_GetPlatform_Call) Run

type OAuthService_Platforms_Call

type OAuthService_Platforms_Call struct {
	*mock.Call
}

OAuthService_Platforms_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Platforms'

func (*OAuthService_Platforms_Call) Return

func (*OAuthService_Platforms_Call) Run

type OAuthService_Redirect_Call

type OAuthService_Redirect_Call struct {
	*mock.Call
}

OAuthService_Redirect_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Redirect'

func (*OAuthService_Redirect_Call) Return

func (*OAuthService_Redirect_Call) Run

type SiteRepo

type SiteRepo struct {
	mock.Mock
}

SiteRepo is an autogenerated mock type for the SiteRepo type

func NewSiteRepo

func NewSiteRepo(t mockConstructorTestingTNewSiteRepo) *SiteRepo

NewSiteRepo creates a new instance of SiteRepo. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*SiteRepo) Create

func (_m *SiteRepo) Create(_a0 context.Context, _a1 model.Site) error

Create provides a mock function with given fields: _a0, _a1

func (*SiteRepo) Del

func (_m *SiteRepo) Del(_a0 context.Context, _a1 model.Site) error

Del provides a mock function with given fields: _a0, _a1

func (*SiteRepo) EXPECT

func (_m *SiteRepo) EXPECT() *SiteRepo_Expecter

func (*SiteRepo) Get

func (_m *SiteRepo) Get(_a0 context.Context, _a1 *dto.Query) ([]model.Site, error)

Get provides a mock function with given fields: _a0, _a1

func (*SiteRepo) GetNews

func (_m *SiteRepo) GetNews(_a0 context.Context, _a1 string, _a2 string) (model.News, error)

GetNews provides a mock function with given fields: _a0, _a1, _a2

func (*SiteRepo) SaveNews

func (_m *SiteRepo) SaveNews(_a0 context.Context, _a1 string, _a2 string, _a3 string) error

SaveNews provides a mock function with given fields: _a0, _a1, _a2, _a3

func (*SiteRepo) Update

func (_m *SiteRepo) Update(_a0 context.Context, _a1 model.Site, _a2 map[string]interface{}) error

Update provides a mock function with given fields: _a0, _a1, _a2

type SiteRepo_Create_Call

type SiteRepo_Create_Call struct {
	*mock.Call
}

SiteRepo_Create_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Create'

func (*SiteRepo_Create_Call) Return

func (*SiteRepo_Create_Call) Run

func (_c *SiteRepo_Create_Call) Run(run func(_a0 context.Context, _a1 model.Site)) *SiteRepo_Create_Call

type SiteRepo_Del_Call

type SiteRepo_Del_Call struct {
	*mock.Call
}

SiteRepo_Del_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Del'

func (*SiteRepo_Del_Call) Return

func (_c *SiteRepo_Del_Call) Return(_a0 error) *SiteRepo_Del_Call

func (*SiteRepo_Del_Call) Run

func (_c *SiteRepo_Del_Call) Run(run func(_a0 context.Context, _a1 model.Site)) *SiteRepo_Del_Call

type SiteRepo_Expecter

type SiteRepo_Expecter struct {
	// contains filtered or unexported fields
}

func (*SiteRepo_Expecter) Create

func (_e *SiteRepo_Expecter) Create(_a0 interface{}, _a1 interface{}) *SiteRepo_Create_Call

Create is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 model.Site

func (*SiteRepo_Expecter) Del

func (_e *SiteRepo_Expecter) Del(_a0 interface{}, _a1 interface{}) *SiteRepo_Del_Call

Del is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 model.Site

func (*SiteRepo_Expecter) Get

func (_e *SiteRepo_Expecter) Get(_a0 interface{}, _a1 interface{}) *SiteRepo_Get_Call

Get is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 *dto.Query

func (*SiteRepo_Expecter) GetNews

func (_e *SiteRepo_Expecter) GetNews(_a0 interface{}, _a1 interface{}, _a2 interface{}) *SiteRepo_GetNews_Call

GetNews is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 string
  • _a2 string

func (*SiteRepo_Expecter) SaveNews

func (_e *SiteRepo_Expecter) SaveNews(_a0 interface{}, _a1 interface{}, _a2 interface{}, _a3 interface{}) *SiteRepo_SaveNews_Call

SaveNews is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 string
  • _a2 string
  • _a3 string

func (*SiteRepo_Expecter) Update

func (_e *SiteRepo_Expecter) Update(_a0 interface{}, _a1 interface{}, _a2 interface{}) *SiteRepo_Update_Call

Update is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 model.Site
  • _a2 map[string]interface{}

type SiteRepo_GetNews_Call

type SiteRepo_GetNews_Call struct {
	*mock.Call
}

SiteRepo_GetNews_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetNews'

func (*SiteRepo_GetNews_Call) Return

func (*SiteRepo_GetNews_Call) Run

func (_c *SiteRepo_GetNews_Call) Run(run func(_a0 context.Context, _a1 string, _a2 string)) *SiteRepo_GetNews_Call

type SiteRepo_Get_Call

type SiteRepo_Get_Call struct {
	*mock.Call
}

SiteRepo_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'

func (*SiteRepo_Get_Call) Return

func (_c *SiteRepo_Get_Call) Return(_a0 []model.Site, _a1 error) *SiteRepo_Get_Call

func (*SiteRepo_Get_Call) Run

func (_c *SiteRepo_Get_Call) Run(run func(_a0 context.Context, _a1 *dto.Query)) *SiteRepo_Get_Call

type SiteRepo_SaveNews_Call

type SiteRepo_SaveNews_Call struct {
	*mock.Call
}

SiteRepo_SaveNews_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'SaveNews'

func (*SiteRepo_SaveNews_Call) Return

func (*SiteRepo_SaveNews_Call) Run

func (_c *SiteRepo_SaveNews_Call) Run(run func(_a0 context.Context, _a1 string, _a2 string, _a3 string)) *SiteRepo_SaveNews_Call

type SiteRepo_Update_Call

type SiteRepo_Update_Call struct {
	*mock.Call
}

SiteRepo_Update_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Update'

func (*SiteRepo_Update_Call) Return

func (*SiteRepo_Update_Call) Run

func (_c *SiteRepo_Update_Call) Run(run func(_a0 context.Context, _a1 model.Site, _a2 map[string]interface{})) *SiteRepo_Update_Call

type SiteService

type SiteService struct {
	mock.Mock
}

SiteService is an autogenerated mock type for the SiteService type

func NewSiteService

func NewSiteService(t mockConstructorTestingTNewSiteService) *SiteService

NewSiteService creates a new instance of SiteService. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*SiteService) Del

func (_m *SiteService) Del(_a0 context.Context, _a1 int) error

Del provides a mock function with given fields: _a0, _a1

func (*SiteService) EXPECT

func (_m *SiteService) EXPECT() *SiteService_Expecter

func (*SiteService) Get

func (_m *SiteService) Get(_a0 context.Context, _a1 *dto.Query) ([]*dto.Site, error)

Get provides a mock function with given fields: _a0, _a1

func (*SiteService) Init

func (_m *SiteService) Init(_a0 context.Context) error

Init provides a mock function with given fields: _a0

func (*SiteService) ListOfIndex

func (_m *SiteService) ListOfIndex(_a0 context.Context) ([]*dto.IndexSite, error)

ListOfIndex provides a mock function with given fields: _a0

func (*SiteService) News

func (_m *SiteService) News(_a0 context.Context, _a1 string, _a2 string) (*dto.News, error)

News provides a mock function with given fields: _a0, _a1, _a2

func (*SiteService) Upsert

func (_m *SiteService) Upsert(_a0 context.Context, _a1 *dto.Site) error

Upsert provides a mock function with given fields: _a0, _a1

type SiteService_Del_Call

type SiteService_Del_Call struct {
	*mock.Call
}

SiteService_Del_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Del'

func (*SiteService_Del_Call) Return

func (*SiteService_Del_Call) Run

func (_c *SiteService_Del_Call) Run(run func(_a0 context.Context, _a1 int)) *SiteService_Del_Call

type SiteService_Expecter

type SiteService_Expecter struct {
	// contains filtered or unexported fields
}

func (*SiteService_Expecter) Del

func (_e *SiteService_Expecter) Del(_a0 interface{}, _a1 interface{}) *SiteService_Del_Call

Del is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 int

func (*SiteService_Expecter) Get

func (_e *SiteService_Expecter) Get(_a0 interface{}, _a1 interface{}) *SiteService_Get_Call

Get is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 *dto.Query

func (*SiteService_Expecter) Init

func (_e *SiteService_Expecter) Init(_a0 interface{}) *SiteService_Init_Call

Init is a helper method to define mock.On call

  • _a0 context.Context

func (*SiteService_Expecter) ListOfIndex

func (_e *SiteService_Expecter) ListOfIndex(_a0 interface{}) *SiteService_ListOfIndex_Call

ListOfIndex is a helper method to define mock.On call

  • _a0 context.Context

func (*SiteService_Expecter) News

func (_e *SiteService_Expecter) News(_a0 interface{}, _a1 interface{}, _a2 interface{}) *SiteService_News_Call

News is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 string
  • _a2 string

func (*SiteService_Expecter) Upsert

func (_e *SiteService_Expecter) Upsert(_a0 interface{}, _a1 interface{}) *SiteService_Upsert_Call

Upsert is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 *dto.Site

type SiteService_Get_Call

type SiteService_Get_Call struct {
	*mock.Call
}

SiteService_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'

func (*SiteService_Get_Call) Return

func (_c *SiteService_Get_Call) Return(_a0 []*dto.Site, _a1 error) *SiteService_Get_Call

func (*SiteService_Get_Call) Run

func (_c *SiteService_Get_Call) Run(run func(_a0 context.Context, _a1 *dto.Query)) *SiteService_Get_Call

type SiteService_Init_Call

type SiteService_Init_Call struct {
	*mock.Call
}

SiteService_Init_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Init'

func (*SiteService_Init_Call) Return

func (*SiteService_Init_Call) Run

type SiteService_ListOfIndex_Call

type SiteService_ListOfIndex_Call struct {
	*mock.Call
}

SiteService_ListOfIndex_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListOfIndex'

func (*SiteService_ListOfIndex_Call) Return

func (*SiteService_ListOfIndex_Call) Run

type SiteService_News_Call

type SiteService_News_Call struct {
	*mock.Call
}

SiteService_News_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'News'

func (*SiteService_News_Call) Return

func (_c *SiteService_News_Call) Return(_a0 *dto.News, _a1 error) *SiteService_News_Call

func (*SiteService_News_Call) Run

func (_c *SiteService_News_Call) Run(run func(_a0 context.Context, _a1 string, _a2 string)) *SiteService_News_Call

type SiteService_Upsert_Call

type SiteService_Upsert_Call struct {
	*mock.Call
}

SiteService_Upsert_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Upsert'

func (*SiteService_Upsert_Call) Return

func (*SiteService_Upsert_Call) Run

type UserRepo

type UserRepo struct {
	mock.Mock
}

UserRepo is an autogenerated mock type for the UserRepo type

func NewUserRepo

func NewUserRepo(t mockConstructorTestingTNewUserRepo) *UserRepo

NewUserRepo creates a new instance of UserRepo. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*UserRepo) CreateUser

func (_m *UserRepo) CreateUser(_a0 context.Context, _a1 model.User) error

CreateUser provides a mock function with given fields: _a0, _a1

func (*UserRepo) EXPECT

func (_m *UserRepo) EXPECT() *UserRepo_Expecter

func (*UserRepo) GetUser

func (_m *UserRepo) GetUser(_a0 context.Context, _a1 *dto.Query) (model.User, error)

GetUser provides a mock function with given fields: _a0, _a1

func (*UserRepo) GetUsers

func (_m *UserRepo) GetUsers(_a0 context.Context, _a1 *dto.Query) ([]model.User, error)

GetUsers provides a mock function with given fields: _a0, _a1

func (*UserRepo) Update

func (_m *UserRepo) Update(_a0 context.Context, _a1 model.User, _a2 map[string]interface{}) error

Update provides a mock function with given fields: _a0, _a1, _a2

type UserRepo_CreateUser_Call

type UserRepo_CreateUser_Call struct {
	*mock.Call
}

UserRepo_CreateUser_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CreateUser'

func (*UserRepo_CreateUser_Call) Return

func (*UserRepo_CreateUser_Call) Run

type UserRepo_Expecter

type UserRepo_Expecter struct {
	// contains filtered or unexported fields
}

func (*UserRepo_Expecter) CreateUser

func (_e *UserRepo_Expecter) CreateUser(_a0 interface{}, _a1 interface{}) *UserRepo_CreateUser_Call

CreateUser is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 model.User

func (*UserRepo_Expecter) GetUser

func (_e *UserRepo_Expecter) GetUser(_a0 interface{}, _a1 interface{}) *UserRepo_GetUser_Call

GetUser is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 *dto.Query

func (*UserRepo_Expecter) GetUsers

func (_e *UserRepo_Expecter) GetUsers(_a0 interface{}, _a1 interface{}) *UserRepo_GetUsers_Call

GetUsers is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 *dto.Query

func (*UserRepo_Expecter) Update

func (_e *UserRepo_Expecter) Update(_a0 interface{}, _a1 interface{}, _a2 interface{}) *UserRepo_Update_Call

Update is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 model.User
  • _a2 map[string]interface{}

type UserRepo_GetUser_Call

type UserRepo_GetUser_Call struct {
	*mock.Call
}

UserRepo_GetUser_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetUser'

func (*UserRepo_GetUser_Call) Return

func (*UserRepo_GetUser_Call) Run

func (_c *UserRepo_GetUser_Call) Run(run func(_a0 context.Context, _a1 *dto.Query)) *UserRepo_GetUser_Call

type UserRepo_GetUsers_Call

type UserRepo_GetUsers_Call struct {
	*mock.Call
}

UserRepo_GetUsers_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetUsers'

func (*UserRepo_GetUsers_Call) Return

func (*UserRepo_GetUsers_Call) Run

func (_c *UserRepo_GetUsers_Call) Run(run func(_a0 context.Context, _a1 *dto.Query)) *UserRepo_GetUsers_Call

type UserRepo_Update_Call

type UserRepo_Update_Call struct {
	*mock.Call
}

UserRepo_Update_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Update'

func (*UserRepo_Update_Call) Return

func (*UserRepo_Update_Call) Run

func (_c *UserRepo_Update_Call) Run(run func(_a0 context.Context, _a1 model.User, _a2 map[string]interface{})) *UserRepo_Update_Call

type UserService

type UserService struct {
	mock.Mock
}

UserService is an autogenerated mock type for the UserService type

func NewUserService

func NewUserService(t mockConstructorTestingTNewUserService) *UserService

NewUserService creates a new instance of UserService. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*UserService) Auth

func (_m *UserService) Auth(_a0 context.Context, _a1 string, _a2 oauth.User) (string, error)

Auth provides a mock function with given fields: _a0, _a1, _a2

func (*UserService) EXPECT

func (_m *UserService) EXPECT() *UserService_Expecter

func (*UserService) GetUser

func (_m *UserService) GetUser(_a0 context.Context, _a1 *dto.Query) (*dto.User, error)

GetUser provides a mock function with given fields: _a0, _a1

func (*UserService) GetUserList

func (_m *UserService) GetUserList(_a0 context.Context) ([]*dto.User, error)

GetUserList provides a mock function with given fields: _a0

func (*UserService) VerifyToken

func (_m *UserService) VerifyToken(_a0 context.Context, _a1 string, _a2 string) bool

VerifyToken provides a mock function with given fields: _a0, _a1, _a2

type UserService_Auth_Call

type UserService_Auth_Call struct {
	*mock.Call
}

UserService_Auth_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Auth'

func (*UserService_Auth_Call) Return

func (*UserService_Auth_Call) Run

func (_c *UserService_Auth_Call) Run(run func(_a0 context.Context, _a1 string, _a2 oauth.User)) *UserService_Auth_Call

type UserService_Expecter

type UserService_Expecter struct {
	// contains filtered or unexported fields
}

func (*UserService_Expecter) Auth

func (_e *UserService_Expecter) Auth(_a0 interface{}, _a1 interface{}, _a2 interface{}) *UserService_Auth_Call

Auth is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 string
  • _a2 oauth.User

func (*UserService_Expecter) GetUser

func (_e *UserService_Expecter) GetUser(_a0 interface{}, _a1 interface{}) *UserService_GetUser_Call

GetUser is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 *dto.Query

func (*UserService_Expecter) GetUserList

func (_e *UserService_Expecter) GetUserList(_a0 interface{}) *UserService_GetUserList_Call

GetUserList is a helper method to define mock.On call

  • _a0 context.Context

func (*UserService_Expecter) VerifyToken

func (_e *UserService_Expecter) VerifyToken(_a0 interface{}, _a1 interface{}, _a2 interface{}) *UserService_VerifyToken_Call

VerifyToken is a helper method to define mock.On call

  • _a0 context.Context
  • _a1 string
  • _a2 string

type UserService_GetUserList_Call

type UserService_GetUserList_Call struct {
	*mock.Call
}

UserService_GetUserList_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetUserList'

func (*UserService_GetUserList_Call) Return

func (*UserService_GetUserList_Call) Run

type UserService_GetUser_Call

type UserService_GetUser_Call struct {
	*mock.Call
}

UserService_GetUser_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetUser'

func (*UserService_GetUser_Call) Return

func (*UserService_GetUser_Call) Run

type UserService_VerifyToken_Call

type UserService_VerifyToken_Call struct {
	*mock.Call
}

UserService_VerifyToken_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'VerifyToken'

func (*UserService_VerifyToken_Call) Return

func (*UserService_VerifyToken_Call) Run

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL