Documentation ¶
Overview ¶
Package fixtures is a generated GoMock package.
Package fixtures is a generated GoMock package.
Package fixtures is a generated GoMock package.
Package fixtures is a generated GoMock package.
Package fixtures is a generated GoMock package.
Index ¶
- func Decode(t *testing.T, r io.Reader, into interface{})
- func Marshal(t *testing.T, payload interface{}) *bytes.Buffer
- func MarshalBytes(t *testing.T, payload interface{}) []byte
- type AuthenticatorMock
- type AuthenticatorMockMockRecorder
- type FranchiseModelMock
- type FranchiseModelMockMockRecorder
- type GameModelMock
- type GameModelMockMockRecorder
- type ServerBuilder
- func (s ServerBuilder) Build() *httptest.Server
- func (s ServerBuilder) Data(data interface{}) ServerBuilder
- func (s ServerBuilder) Method(method string) ServerBuilder
- func (s ServerBuilder) Path(path string) ServerBuilder
- func (s ServerBuilder) Query(query string) ServerBuilder
- func (s ServerBuilder) Return(responseCode int) ServerBuilder
- func (s ServerBuilder) Token(token string) ServerBuilder
- type UserGamesModelMock
- func (m *UserGamesModelMock) ChangeGameProgress(arg0, arg1 string, arg2 *models.UserGameProgress) error
- func (m *UserGamesModelMock) ChangeGameStatus(arg0, arg1 string, arg2 models.Status) error
- func (m *UserGamesModelMock) DeleteUserGame(arg0 string) error
- func (m *UserGamesModelMock) EXPECT() *UserGamesModelMockMockRecorder
- func (m *UserGamesModelMock) GetAvailableGamesFor(arg0 string) ([]*models.Game, error)
- func (m *UserGamesModelMock) GetUserGames(arg0 string) ([]*models.UserGame, error)
- func (m *UserGamesModelMock) GetUserGamesGrouped(arg0 string) (map[models.Status][]*models.UserGame, error)
- func (m *UserGamesModelMock) LinkGameToUser(arg0, arg1 string, arg2 *models.UserGameProgress) error
- type UserGamesModelMockMockRecorder
- func (mr *UserGamesModelMockMockRecorder) ChangeGameProgress(arg0, arg1, arg2 interface{}) *gomock.Call
- func (mr *UserGamesModelMockMockRecorder) ChangeGameStatus(arg0, arg1, arg2 interface{}) *gomock.Call
- func (mr *UserGamesModelMockMockRecorder) DeleteUserGame(arg0 interface{}) *gomock.Call
- func (mr *UserGamesModelMockMockRecorder) GetAvailableGamesFor(arg0 interface{}) *gomock.Call
- func (mr *UserGamesModelMockMockRecorder) GetUserGames(arg0 interface{}) *gomock.Call
- func (mr *UserGamesModelMockMockRecorder) GetUserGamesGrouped(arg0 interface{}) *gomock.Call
- func (mr *UserGamesModelMockMockRecorder) LinkGameToUser(arg0, arg1, arg2 interface{}) *gomock.Call
- type UserModelMock
- func (m *UserModelMock) AssociateTokenWithUser(arg0, arg1 string) error
- func (m *UserModelMock) Authenticate(arg0, arg1 string) (*models.User, error)
- func (m *UserModelMock) EXPECT() *UserModelMockMockRecorder
- func (m *UserModelMock) GetUserByToken(arg0 string) (*models.User, error)
- func (m *UserModelMock) Insert(arg0 *models.User) (*models.User, error)
- func (m *UserModelMock) InvalidateToken(arg0, arg1 string) error
- type UserModelMockMockRecorder
- func (mr *UserModelMockMockRecorder) AssociateTokenWithUser(arg0, arg1 interface{}) *gomock.Call
- func (mr *UserModelMockMockRecorder) Authenticate(arg0, arg1 interface{}) *gomock.Call
- func (mr *UserModelMockMockRecorder) GetUserByToken(arg0 interface{}) *gomock.Call
- func (mr *UserModelMockMockRecorder) Insert(arg0 interface{}) *gomock.Call
- func (mr *UserModelMockMockRecorder) InvalidateToken(arg0, arg1 interface{}) *gomock.Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Marshal ¶
Marshal unmarshalls the payload and returns a *bytes.Buffer with the content, or fails the test if unable to
func MarshalBytes ¶
MarshalBytes unmarshals the payload and returns a []byte with the content, or fails the test if unable to
Types ¶
type AuthenticatorMock ¶
type AuthenticatorMock struct {
// contains filtered or unexported fields
}
AuthenticatorMock is a mock of Authenticator interface
func NewAuthenticatorMock ¶
func NewAuthenticatorMock(ctrl *gomock.Controller) *AuthenticatorMock
NewAuthenticatorMock creates a new mock instance
func (*AuthenticatorMock) DecodeToken ¶
func (m *AuthenticatorMock) DecodeToken(arg0 string) (*models.User, error)
DecodeToken mocks base method
func (*AuthenticatorMock) EXPECT ¶
func (m *AuthenticatorMock) EXPECT() *AuthenticatorMockMockRecorder
EXPECT returns an object that allows the caller to indicate expected use
func (*AuthenticatorMock) NewTokenForUser ¶
func (m *AuthenticatorMock) NewTokenForUser(arg0 *models.User) (string, error)
NewTokenForUser mocks base method
type AuthenticatorMockMockRecorder ¶
type AuthenticatorMockMockRecorder struct {
// contains filtered or unexported fields
}
AuthenticatorMockMockRecorder is the mock recorder for AuthenticatorMock
func (*AuthenticatorMockMockRecorder) DecodeToken ¶
func (mr *AuthenticatorMockMockRecorder) DecodeToken(arg0 interface{}) *gomock.Call
DecodeToken indicates an expected call of DecodeToken
func (*AuthenticatorMockMockRecorder) NewTokenForUser ¶
func (mr *AuthenticatorMockMockRecorder) NewTokenForUser(arg0 interface{}) *gomock.Call
NewTokenForUser indicates an expected call of NewTokenForUser
type FranchiseModelMock ¶
type FranchiseModelMock struct {
// contains filtered or unexported fields
}
FranchiseModelMock is a mock of FranchiseModel interface
func NewFranchiseModelMock ¶
func NewFranchiseModelMock(ctrl *gomock.Controller) *FranchiseModelMock
NewFranchiseModelMock creates a new mock instance
func (*FranchiseModelMock) All ¶
func (m *FranchiseModelMock) All() ([]*models.Franchise, error)
All mocks base method
func (*FranchiseModelMock) EXPECT ¶
func (m *FranchiseModelMock) EXPECT() *FranchiseModelMockMockRecorder
EXPECT returns an object that allows the caller to indicate expected use
type FranchiseModelMockMockRecorder ¶
type FranchiseModelMockMockRecorder struct {
// contains filtered or unexported fields
}
FranchiseModelMockMockRecorder is the mock recorder for FranchiseModelMock
func (*FranchiseModelMockMockRecorder) All ¶
func (mr *FranchiseModelMockMockRecorder) All() *gomock.Call
All indicates an expected call of All
func (*FranchiseModelMockMockRecorder) Insert ¶
func (mr *FranchiseModelMockMockRecorder) Insert(arg0 interface{}) *gomock.Call
Insert indicates an expected call of Insert
type GameModelMock ¶
type GameModelMock struct {
// contains filtered or unexported fields
}
GameModelMock is a mock of GameModel interface
func NewGameModelMock ¶
func NewGameModelMock(ctrl *gomock.Controller) *GameModelMock
NewGameModelMock creates a new mock instance
func (*GameModelMock) All ¶
func (m *GameModelMock) All() ([]*models.Game, error)
All mocks base method
func (*GameModelMock) EXPECT ¶
func (m *GameModelMock) EXPECT() *GameModelMockMockRecorder
EXPECT returns an object that allows the caller to indicate expected use
type GameModelMockMockRecorder ¶
type GameModelMockMockRecorder struct {
// contains filtered or unexported fields
}
GameModelMockMockRecorder is the mock recorder for GameModelMock
func (*GameModelMockMockRecorder) All ¶
func (mr *GameModelMockMockRecorder) All() *gomock.Call
All indicates an expected call of All
func (*GameModelMockMockRecorder) Get ¶
func (mr *GameModelMockMockRecorder) Get(arg0 interface{}) *gomock.Call
Get indicates an expected call of Get
func (*GameModelMockMockRecorder) Insert ¶
func (mr *GameModelMockMockRecorder) Insert(arg0 interface{}) *gomock.Call
Insert indicates an expected call of Insert
type ServerBuilder ¶
type ServerBuilder struct {
// contains filtered or unexported fields
}
func NewTestServer ¶
func NewTestServer(t *testing.T) ServerBuilder
func (ServerBuilder) Build ¶
func (s ServerBuilder) Build() *httptest.Server
func (ServerBuilder) Data ¶
func (s ServerBuilder) Data(data interface{}) ServerBuilder
func (ServerBuilder) Method ¶
func (s ServerBuilder) Method(method string) ServerBuilder
func (ServerBuilder) Path ¶
func (s ServerBuilder) Path(path string) ServerBuilder
func (ServerBuilder) Query ¶
func (s ServerBuilder) Query(query string) ServerBuilder
func (ServerBuilder) Return ¶
func (s ServerBuilder) Return(responseCode int) ServerBuilder
func (ServerBuilder) Token ¶
func (s ServerBuilder) Token(token string) ServerBuilder
type UserGamesModelMock ¶
type UserGamesModelMock struct {
// contains filtered or unexported fields
}
UserGamesModelMock is a mock of UserGamesModel interface
func NewUserGamesModelMock ¶
func NewUserGamesModelMock(ctrl *gomock.Controller) *UserGamesModelMock
NewUserGamesModelMock creates a new mock instance
func (*UserGamesModelMock) ChangeGameProgress ¶
func (m *UserGamesModelMock) ChangeGameProgress(arg0, arg1 string, arg2 *models.UserGameProgress) error
ChangeGameProgress mocks base method
func (*UserGamesModelMock) ChangeGameStatus ¶
func (m *UserGamesModelMock) ChangeGameStatus(arg0, arg1 string, arg2 models.Status) error
ChangeGameStatus mocks base method
func (*UserGamesModelMock) DeleteUserGame ¶
func (m *UserGamesModelMock) DeleteUserGame(arg0 string) error
DeleteUserGame mocks base method
func (*UserGamesModelMock) EXPECT ¶
func (m *UserGamesModelMock) EXPECT() *UserGamesModelMockMockRecorder
EXPECT returns an object that allows the caller to indicate expected use
func (*UserGamesModelMock) GetAvailableGamesFor ¶
func (m *UserGamesModelMock) GetAvailableGamesFor(arg0 string) ([]*models.Game, error)
GetAvailableGamesFor mocks base method
func (*UserGamesModelMock) GetUserGames ¶
func (m *UserGamesModelMock) GetUserGames(arg0 string) ([]*models.UserGame, error)
GetUserGames mocks base method
func (*UserGamesModelMock) GetUserGamesGrouped ¶
func (m *UserGamesModelMock) GetUserGamesGrouped(arg0 string) (map[models.Status][]*models.UserGame, error)
GetUserGamesGrouped mocks base method
func (*UserGamesModelMock) LinkGameToUser ¶
func (m *UserGamesModelMock) LinkGameToUser(arg0, arg1 string, arg2 *models.UserGameProgress) error
LinkGameToUser mocks base method
type UserGamesModelMockMockRecorder ¶
type UserGamesModelMockMockRecorder struct {
// contains filtered or unexported fields
}
UserGamesModelMockMockRecorder is the mock recorder for UserGamesModelMock
func (*UserGamesModelMockMockRecorder) ChangeGameProgress ¶
func (mr *UserGamesModelMockMockRecorder) ChangeGameProgress(arg0, arg1, arg2 interface{}) *gomock.Call
ChangeGameProgress indicates an expected call of ChangeGameProgress
func (*UserGamesModelMockMockRecorder) ChangeGameStatus ¶
func (mr *UserGamesModelMockMockRecorder) ChangeGameStatus(arg0, arg1, arg2 interface{}) *gomock.Call
ChangeGameStatus indicates an expected call of ChangeGameStatus
func (*UserGamesModelMockMockRecorder) DeleteUserGame ¶
func (mr *UserGamesModelMockMockRecorder) DeleteUserGame(arg0 interface{}) *gomock.Call
DeleteUserGame indicates an expected call of DeleteUserGame
func (*UserGamesModelMockMockRecorder) GetAvailableGamesFor ¶
func (mr *UserGamesModelMockMockRecorder) GetAvailableGamesFor(arg0 interface{}) *gomock.Call
GetAvailableGamesFor indicates an expected call of GetAvailableGamesFor
func (*UserGamesModelMockMockRecorder) GetUserGames ¶
func (mr *UserGamesModelMockMockRecorder) GetUserGames(arg0 interface{}) *gomock.Call
GetUserGames indicates an expected call of GetUserGames
func (*UserGamesModelMockMockRecorder) GetUserGamesGrouped ¶
func (mr *UserGamesModelMockMockRecorder) GetUserGamesGrouped(arg0 interface{}) *gomock.Call
GetUserGamesGrouped indicates an expected call of GetUserGamesGrouped
func (*UserGamesModelMockMockRecorder) LinkGameToUser ¶
func (mr *UserGamesModelMockMockRecorder) LinkGameToUser(arg0, arg1, arg2 interface{}) *gomock.Call
LinkGameToUser indicates an expected call of LinkGameToUser
type UserModelMock ¶
type UserModelMock struct {
// contains filtered or unexported fields
}
UserModelMock is a mock of UserModel interface
func NewUserModelMock ¶
func NewUserModelMock(ctrl *gomock.Controller) *UserModelMock
NewUserModelMock creates a new mock instance
func (*UserModelMock) AssociateTokenWithUser ¶
func (m *UserModelMock) AssociateTokenWithUser(arg0, arg1 string) error
AssociateTokenWithUser mocks base method
func (*UserModelMock) Authenticate ¶
func (m *UserModelMock) Authenticate(arg0, arg1 string) (*models.User, error)
Authenticate mocks base method
func (*UserModelMock) EXPECT ¶
func (m *UserModelMock) EXPECT() *UserModelMockMockRecorder
EXPECT returns an object that allows the caller to indicate expected use
func (*UserModelMock) GetUserByToken ¶
func (m *UserModelMock) GetUserByToken(arg0 string) (*models.User, error)
GetUserByToken mocks base method
func (*UserModelMock) InvalidateToken ¶
func (m *UserModelMock) InvalidateToken(arg0, arg1 string) error
InvalidateToken mocks base method
type UserModelMockMockRecorder ¶
type UserModelMockMockRecorder struct {
// contains filtered or unexported fields
}
UserModelMockMockRecorder is the mock recorder for UserModelMock
func (*UserModelMockMockRecorder) AssociateTokenWithUser ¶
func (mr *UserModelMockMockRecorder) AssociateTokenWithUser(arg0, arg1 interface{}) *gomock.Call
AssociateTokenWithUser indicates an expected call of AssociateTokenWithUser
func (*UserModelMockMockRecorder) Authenticate ¶
func (mr *UserModelMockMockRecorder) Authenticate(arg0, arg1 interface{}) *gomock.Call
Authenticate indicates an expected call of Authenticate
func (*UserModelMockMockRecorder) GetUserByToken ¶
func (mr *UserModelMockMockRecorder) GetUserByToken(arg0 interface{}) *gomock.Call
GetUserByToken indicates an expected call of GetUserByToken
func (*UserModelMockMockRecorder) Insert ¶
func (mr *UserModelMockMockRecorder) Insert(arg0 interface{}) *gomock.Call
Insert indicates an expected call of Insert
func (*UserModelMockMockRecorder) InvalidateToken ¶
func (mr *UserModelMockMockRecorder) InvalidateToken(arg0, arg1 interface{}) *gomock.Call
InvalidateToken indicates an expected call of InvalidateToken