db

package
v0.0.0-...-8126430 Latest Latest
Warning

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

Go to latest
Published: May 30, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Querier

type Querier struct {
	mock.Mock
}

Querier is an autogenerated mock type for the Querier type

func NewQuerier

func NewQuerier(t interface {
	mock.TestingT
	Cleanup(func())
}) *Querier

NewQuerier creates a new instance of Querier. 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 (*Querier) DecreaseDeployableTroops

func (_m *Querier) DecreaseDeployableTroops(ctx context.Context, arg sqlc.DecreaseDeployableTroopsParams) error

DecreaseDeployableTroops provides a mock function with given fields: ctx, arg

func (*Querier) EXPECT

func (_m *Querier) EXPECT() *Querier_Expecter

func (*Querier) ExecuteInTransaction

func (_m *Querier) ExecuteInTransaction(ctx context.Context, txFunc func(db.Querier) (interface{}, error)) (interface{}, error)

ExecuteInTransaction provides a mock function with given fields: ctx, txFunc

func (*Querier) ExecuteInTransactionWithIsolation

func (_m *Querier) ExecuteInTransactionWithIsolation(ctx context.Context, isolationLevel pgx.TxIsoLevel, txFunc func(db.Querier) (interface{}, error)) (interface{}, error)

ExecuteInTransactionWithIsolation provides a mock function with given fields: ctx, isolationLevel, txFunc

func (*Querier) GetGame

func (_m *Querier) GetGame(ctx context.Context, id int64) (sqlc.Game, error)

GetGame provides a mock function with given fields: ctx, id

func (*Querier) GetPlayerByUserId

func (_m *Querier) GetPlayerByUserId(ctx context.Context, userID string) (sqlc.Player, error)

GetPlayerByUserId provides a mock function with given fields: ctx, userID

func (*Querier) GetPlayersByGame

func (_m *Querier) GetPlayersByGame(ctx context.Context, gameID int64) ([]sqlc.Player, error)

GetPlayersByGame provides a mock function with given fields: ctx, gameID

func (*Querier) GetRegionsByGame

func (_m *Querier) GetRegionsByGame(ctx context.Context, id int64) ([]sqlc.GetRegionsByGameRow, error)

GetRegionsByGame provides a mock function with given fields: ctx, id

func (*Querier) IncreaseRegionTroops

func (_m *Querier) IncreaseRegionTroops(ctx context.Context, arg sqlc.IncreaseRegionTroopsParams) error

IncreaseRegionTroops provides a mock function with given fields: ctx, arg

func (*Querier) InsertGame

func (_m *Querier) InsertGame(ctx context.Context) (int64, error)

InsertGame provides a mock function with given fields: ctx

func (*Querier) InsertPlayers

func (_m *Querier) InsertPlayers(ctx context.Context, arg []sqlc.InsertPlayersParams) (int64, error)

InsertPlayers provides a mock function with given fields: ctx, arg

func (*Querier) InsertRegions

func (_m *Querier) InsertRegions(ctx context.Context, arg []sqlc.InsertRegionsParams) (int64, error)

InsertRegions provides a mock function with given fields: ctx, arg

func (*Querier) SetGamePhase

func (_m *Querier) SetGamePhase(ctx context.Context, arg sqlc.SetGamePhaseParams) error

SetGamePhase provides a mock function with given fields: ctx, arg

type Querier_DecreaseDeployableTroops_Call

type Querier_DecreaseDeployableTroops_Call struct {
	*mock.Call
}

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

func (*Querier_DecreaseDeployableTroops_Call) Return

func (*Querier_DecreaseDeployableTroops_Call) Run

type Querier_ExecuteInTransactionWithIsolation_Call

type Querier_ExecuteInTransactionWithIsolation_Call struct {
	*mock.Call
}

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

func (*Querier_ExecuteInTransactionWithIsolation_Call) Return

func (*Querier_ExecuteInTransactionWithIsolation_Call) Run

func (*Querier_ExecuteInTransactionWithIsolation_Call) RunAndReturn

type Querier_ExecuteInTransaction_Call

type Querier_ExecuteInTransaction_Call struct {
	*mock.Call
}

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

func (*Querier_ExecuteInTransaction_Call) Return

func (*Querier_ExecuteInTransaction_Call) Run

func (_c *Querier_ExecuteInTransaction_Call) Run(run func(ctx context.Context, txFunc func(db.Querier) (interface{}, error))) *Querier_ExecuteInTransaction_Call

func (*Querier_ExecuteInTransaction_Call) RunAndReturn

func (_c *Querier_ExecuteInTransaction_Call) RunAndReturn(run func(context.Context, func(db.Querier) (interface{}, error)) (interface{}, error)) *Querier_ExecuteInTransaction_Call

type Querier_Expecter

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

func (*Querier_Expecter) DecreaseDeployableTroops

func (_e *Querier_Expecter) DecreaseDeployableTroops(ctx interface{}, arg interface{}) *Querier_DecreaseDeployableTroops_Call

DecreaseDeployableTroops is a helper method to define mock.On call

  • ctx context.Context
  • arg sqlc.DecreaseDeployableTroopsParams

func (*Querier_Expecter) ExecuteInTransaction

func (_e *Querier_Expecter) ExecuteInTransaction(ctx interface{}, txFunc interface{}) *Querier_ExecuteInTransaction_Call

ExecuteInTransaction is a helper method to define mock.On call

  • ctx context.Context
  • txFunc func(db.Querier)(interface{} , error)

func (*Querier_Expecter) ExecuteInTransactionWithIsolation

func (_e *Querier_Expecter) ExecuteInTransactionWithIsolation(ctx interface{}, isolationLevel interface{}, txFunc interface{}) *Querier_ExecuteInTransactionWithIsolation_Call

ExecuteInTransactionWithIsolation is a helper method to define mock.On call

  • ctx context.Context
  • isolationLevel pgx.TxIsoLevel
  • txFunc func(db.Querier)(interface{} , error)

func (*Querier_Expecter) GetGame

func (_e *Querier_Expecter) GetGame(ctx interface{}, id interface{}) *Querier_GetGame_Call

GetGame is a helper method to define mock.On call

  • ctx context.Context
  • id int64

func (*Querier_Expecter) GetPlayerByUserId

func (_e *Querier_Expecter) GetPlayerByUserId(ctx interface{}, userID interface{}) *Querier_GetPlayerByUserId_Call

GetPlayerByUserId is a helper method to define mock.On call

  • ctx context.Context
  • userID string

func (*Querier_Expecter) GetPlayersByGame

func (_e *Querier_Expecter) GetPlayersByGame(ctx interface{}, gameID interface{}) *Querier_GetPlayersByGame_Call

GetPlayersByGame is a helper method to define mock.On call

  • ctx context.Context
  • gameID int64

func (*Querier_Expecter) GetRegionsByGame

func (_e *Querier_Expecter) GetRegionsByGame(ctx interface{}, id interface{}) *Querier_GetRegionsByGame_Call

GetRegionsByGame is a helper method to define mock.On call

  • ctx context.Context
  • id int64

func (*Querier_Expecter) IncreaseRegionTroops

func (_e *Querier_Expecter) IncreaseRegionTroops(ctx interface{}, arg interface{}) *Querier_IncreaseRegionTroops_Call

IncreaseRegionTroops is a helper method to define mock.On call

  • ctx context.Context
  • arg sqlc.IncreaseRegionTroopsParams

func (*Querier_Expecter) InsertGame

func (_e *Querier_Expecter) InsertGame(ctx interface{}) *Querier_InsertGame_Call

InsertGame is a helper method to define mock.On call

  • ctx context.Context

func (*Querier_Expecter) InsertPlayers

func (_e *Querier_Expecter) InsertPlayers(ctx interface{}, arg interface{}) *Querier_InsertPlayers_Call

InsertPlayers is a helper method to define mock.On call

  • ctx context.Context
  • arg []sqlc.InsertPlayersParams

func (*Querier_Expecter) InsertRegions

func (_e *Querier_Expecter) InsertRegions(ctx interface{}, arg interface{}) *Querier_InsertRegions_Call

InsertRegions is a helper method to define mock.On call

  • ctx context.Context
  • arg []sqlc.InsertRegionsParams

func (*Querier_Expecter) SetGamePhase

func (_e *Querier_Expecter) SetGamePhase(ctx interface{}, arg interface{}) *Querier_SetGamePhase_Call

SetGamePhase is a helper method to define mock.On call

  • ctx context.Context
  • arg sqlc.SetGamePhaseParams

type Querier_GetGame_Call

type Querier_GetGame_Call struct {
	*mock.Call
}

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

func (*Querier_GetGame_Call) Return

func (*Querier_GetGame_Call) Run

func (_c *Querier_GetGame_Call) Run(run func(ctx context.Context, id int64)) *Querier_GetGame_Call

func (*Querier_GetGame_Call) RunAndReturn

func (_c *Querier_GetGame_Call) RunAndReturn(run func(context.Context, int64) (sqlc.Game, error)) *Querier_GetGame_Call

type Querier_GetPlayerByUserId_Call

type Querier_GetPlayerByUserId_Call struct {
	*mock.Call
}

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

func (*Querier_GetPlayerByUserId_Call) Return

func (*Querier_GetPlayerByUserId_Call) Run

func (*Querier_GetPlayerByUserId_Call) RunAndReturn

type Querier_GetPlayersByGame_Call

type Querier_GetPlayersByGame_Call struct {
	*mock.Call
}

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

func (*Querier_GetPlayersByGame_Call) Return

func (*Querier_GetPlayersByGame_Call) Run

func (*Querier_GetPlayersByGame_Call) RunAndReturn

type Querier_GetRegionsByGame_Call

type Querier_GetRegionsByGame_Call struct {
	*mock.Call
}

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

func (*Querier_GetRegionsByGame_Call) Return

func (*Querier_GetRegionsByGame_Call) Run

func (*Querier_GetRegionsByGame_Call) RunAndReturn

type Querier_IncreaseRegionTroops_Call

type Querier_IncreaseRegionTroops_Call struct {
	*mock.Call
}

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

func (*Querier_IncreaseRegionTroops_Call) Return

func (*Querier_IncreaseRegionTroops_Call) Run

func (*Querier_IncreaseRegionTroops_Call) RunAndReturn

type Querier_InsertGame_Call

type Querier_InsertGame_Call struct {
	*mock.Call
}

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

func (*Querier_InsertGame_Call) Return

func (*Querier_InsertGame_Call) Run

func (*Querier_InsertGame_Call) RunAndReturn

type Querier_InsertPlayers_Call

type Querier_InsertPlayers_Call struct {
	*mock.Call
}

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

func (*Querier_InsertPlayers_Call) Return

func (*Querier_InsertPlayers_Call) Run

func (*Querier_InsertPlayers_Call) RunAndReturn

type Querier_InsertRegions_Call

type Querier_InsertRegions_Call struct {
	*mock.Call
}

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

func (*Querier_InsertRegions_Call) Return

func (*Querier_InsertRegions_Call) Run

func (*Querier_InsertRegions_Call) RunAndReturn

type Querier_SetGamePhase_Call

type Querier_SetGamePhase_Call struct {
	*mock.Call
}

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

func (*Querier_SetGamePhase_Call) Return

func (*Querier_SetGamePhase_Call) Run

func (*Querier_SetGamePhase_Call) RunAndReturn

Jump to

Keyboard shortcuts

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