mock

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: May 5, 2020 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MockUserNameValue          = `test`
	MockUserHealthValue        = 20
	MockUserXpValue            = 10
	MockUserPosXValue          = 1
	MockUserPosYValue          = 2
	MockUserPosZValue          = 3
	MockMessageValue           = `value`
	MockMinecraftHostnameValue = `domain`
)

Variables

This section is empty.

Functions

This section is empty.

Types

type BotSenderMockInvalid

type BotSenderMockInvalid struct{}

func (*BotSenderMockInvalid) SendTextMessage

func (sender *BotSenderMockInvalid) SendTextMessage(msg string) error

type BotSenderMockValid

type BotSenderMockValid struct {
	Msg string
}

func (*BotSenderMockValid) SendTextMessageToChannels

func (sender *BotSenderMockValid) SendTextMessageToChannels(msg string) error

type RconClientMockInvalid

type RconClientMockInvalid struct {
}

func (*RconClientMockInvalid) DataGetEntity

func (r *RconClientMockInvalid) DataGetEntity(string) (*rcon.User, error)

func (*RconClientMockInvalid) List

func (r *RconClientMockInvalid) List() ([]string, error)

func (*RconClientMockInvalid) Title

func (r *RconClientMockInvalid) Title(string) ([]string, error)

func (*RconClientMockInvalid) WhitelistAdd

func (r *RconClientMockInvalid) WhitelistAdd(string) error

func (*RconClientMockInvalid) WhitelistList

func (r *RconClientMockInvalid) WhitelistList() ([]string, error)

func (*RconClientMockInvalid) WhitelistRemove

func (r *RconClientMockInvalid) WhitelistRemove(string) error

type RconClientMockValid

type RconClientMockValid struct {
	LoginUsernames       []string
	WhitelistedUsernames []string
}

func (*RconClientMockValid) DataGetEntity

func (r *RconClientMockValid) DataGetEntity(string) (*rcon.User, error)

func (*RconClientMockValid) List

func (r *RconClientMockValid) List() ([]string, error)

func (*RconClientMockValid) Title

func (r *RconClientMockValid) Title(string) ([]string, error)

func (*RconClientMockValid) WhitelistAdd

func (r *RconClientMockValid) WhitelistAdd(username string) error

func (*RconClientMockValid) WhitelistList

func (r *RconClientMockValid) WhitelistList() ([]string, error)

func (*RconClientMockValid) WhitelistRemove

func (r *RconClientMockValid) WhitelistRemove(username string) error

type SharedmemMockInvalid

type SharedmemMockInvalid struct {
}

func (*SharedmemMockInvalid) AsyncPublishMessage

func (m *SharedmemMockInvalid) AsyncPublishMessage(data domain.Message) error

func (*SharedmemMockInvalid) AsyncWriteEntity

func (m *SharedmemMockInvalid) AsyncWriteEntity(data domain.Entity) error

func (*SharedmemMockInvalid) NewSubscriber

func (m *SharedmemMockInvalid) NewSubscriber() (sharedmem.Subscriber, error)

func (*SharedmemMockInvalid) SyncReadEntity

func (m *SharedmemMockInvalid) SyncReadEntity() (domain.Entity, error)

type SharedmemMockValid

type SharedmemMockValid struct {
	Data *domain.Entity
}

func (*SharedmemMockValid) AsyncPublishMessage

func (m *SharedmemMockValid) AsyncPublishMessage(data domain.Message) error

func (*SharedmemMockValid) AsyncWriteEntity

func (m *SharedmemMockValid) AsyncWriteEntity(data domain.Entity) error

func (*SharedmemMockValid) NewSubscriber

func (m *SharedmemMockValid) NewSubscriber() (sharedmem.Subscriber, error)

func (*SharedmemMockValid) SyncReadEntity

func (m *SharedmemMockValid) SyncReadEntity() (domain.Entity, error)

type SubscriberMockInvalid

type SubscriberMockInvalid struct{}

func (*SubscriberMockInvalid) SyncSubscribeMessage

func (m *SubscriberMockInvalid) SyncSubscribeMessage() (domain.Message, error)

type SubscriberMockValid

type SubscriberMockValid struct{}

func (*SubscriberMockValid) SyncSubscribeMessage

func (sub *SubscriberMockValid) SyncSubscribeMessage() (domain.Message, error)

Jump to

Keyboard shortcuts

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