mockutil

package
v0.0.0-...-0d78db7 Latest Latest
Warning

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

Go to latest
Published: Dec 7, 2024 License: AGPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockManager

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

func NewMockManager

func NewMockManager(t *testing.T, opts ...MockOption) *MockManager

func (*MockManager) Messenger

func (m *MockManager) Messenger() *testutil.Messenger

func (*MockManager) PlayerHelper

func (m *MockManager) PlayerHelper() *mocks.MockPlayerHelper

func (*MockManager) Players

func (m *MockManager) Players() []*player.Player

func (*MockManager) Subscriber

func (m *MockManager) Subscriber() *testutil.Subscriber

func (*MockManager) TeamRepository

func (m *MockManager) TeamRepository() *mocks.MockTeamRepository

func (*MockManager) Tx

func (m *MockManager) Tx() *world.Tx

func (*MockManager) UserRepository

func (m *MockManager) UserRepository() *mocks.MockUserRepository

type MockOption

type MockOption func(*MockManager)

func WithMessenger

func WithMessenger(m *testutil.Messenger) MockOption

func WithPlayerHelper

func WithPlayerHelper(helper *mocks.MockPlayerHelper) MockOption

func WithPlayers

func WithPlayers(players ...*player.Player) MockOption

func WithSubscriber

func WithSubscriber(sub *testutil.Subscriber) MockOption

func WithTeamRepository

func WithTeamRepository(t *mocks.MockTeamRepository) MockOption

func WithTx

func WithTx(tx *world.Tx) MockOption

func WithUserRepository

func WithUserRepository(u *mocks.MockUserRepository) MockOption

Jump to

Keyboard shortcuts

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