Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitBaseSuite ¶
func InitBaseSuite[T BaseSuiteInterface](realSuite T)
func InitBaseSuiteWithServer ¶
func InitBaseSuiteWithServer[T BaseSuiteWithServerInterface](srv T)
Types ¶
type BaseSuite ¶
type BaseSuite struct {
suite.Suite
Repository *repositories.Repository
}
func (*BaseSuite) GetRepository ¶
func (suite *BaseSuite) GetRepository() *repositories.Repository
func (*BaseSuite) SetRepository ¶
func (suite *BaseSuite) SetRepository(repo *repositories.Repository)
func (*BaseSuite) TearDownTest ¶
func (suite *BaseSuite) TearDownTest()
type BaseSuiteInterface ¶
type BaseSuiteInterface interface {
HasLifecycleMethods
HasRepo
}
type BaseSuiteWithServer ¶
type BaseSuiteWithServer struct {
BaseSuite
TestHTTPServer
}
func (*BaseSuiteWithServer) GetRepository ¶
func (s *BaseSuiteWithServer) GetRepository() *repositories.Repository
func (*BaseSuiteWithServer) GetServer ¶
func (s *BaseSuiteWithServer) GetServer() *httptest.Server
func (*BaseSuiteWithServer) SetRepository ¶
func (s *BaseSuiteWithServer) SetRepository(repo *repositories.Repository)
func (*BaseSuiteWithServer) SetServer ¶
func (s *BaseSuiteWithServer) SetServer(srv *httptest.Server)
type BaseSuiteWithServerInterface ¶
type BaseSuiteWithServerInterface interface {
BaseSuiteInterface
HasServer
}
type HasLifecycleMethods ¶
type HasLifecycleMethods interface {
SetupTest()
TearDownTest()
}
type HasRepo ¶
type HasRepo interface {
SetRepository(repo *repositories.Repository)
GetRepository() *repositories.Repository
}
type TestHTTPServer ¶
Click to show internal directories.
Click to hide internal directories.