testutil

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2025 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetFreePort

func GetFreePort() (int, error)

GetFreePort 테스트용으로 사용 가능한 임의의 포트를 반환합니다.

func WaitForServer

func WaitForServer(port int, timeout time.Duration) error

WaitForServer 서버가 해당 포트에서 리스닝할 때까지 대기합니다.

Types

type MockNotificationSender

type MockNotificationSender struct {
	NotifyCalled      bool
	LastNotifierID    string
	LastTitle         string
	LastMessage       string
	LastErrorOccurred bool
	ShouldFail        bool

	NotifyDefaultCalled bool
	// contains filtered or unexported fields
}

MockNotificationSender NotificationService의 테스트용 Mock 구현체입니다. service/api 및 하위 패키지(v1/handler 등) 테스트에서 공통으로 사용됩니다.

func (*MockNotificationSender) NotifyDefault

func (m *MockNotificationSender) NotifyDefault(message string) bool

func (*MockNotificationSender) NotifyDefaultWithError

func (m *MockNotificationSender) NotifyDefaultWithError(message string) bool

func (*MockNotificationSender) NotifyWithTitle

func (m *MockNotificationSender) NotifyWithTitle(notifierID string, title string, message string, errorOccurred bool) bool

func (*MockNotificationSender) Reset

func (m *MockNotificationSender) Reset()

Reset 상태를 초기화합니다.

Jump to

Keyboard shortcuts

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