integrationtestutil

package
v0.19.2 Latest Latest
Warning

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

Go to latest
Published: Nov 4, 2025 License: AGPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateOrgProjectAndAssetAssetVersion

func CreateOrgProjectAndAssetAssetVersion(db core.DB) (models.Org, models.Project, models.Asset, models.AssetVersion)

func InitDatabaseContainer

func InitDatabaseContainer(initDBSQLPath string) (core.DB, func())

func InitSQLDatabaseContainer

func InitSQLDatabaseContainer(initDBSQLPath string) (string, string, string, string, string, func())

InitSQLDatabaseContainer initializes a test database container and returns the underlying SQL DB and connection string instead of GORM DB. Useful for components that need direct SQL access.

func NewContext

func NewContext(r *http.Request, w http.ResponseWriter) core.Context

Types

type TestGitlabClientFactory

type TestGitlabClientFactory struct {
	*mocks.GitlabClientFacade
}

func (TestGitlabClientFactory) FromAccessToken

func (f TestGitlabClientFactory) FromAccessToken(accessToken string, baseURL string) (core.GitlabClientFacade, error)

func (TestGitlabClientFactory) FromIntegration

func (TestGitlabClientFactory) FromIntegrationUUID

func (f TestGitlabClientFactory) FromIntegrationUUID(id uuid.UUID) (core.GitlabClientFacade, error)

func (TestGitlabClientFactory) FromOauth2Token

func (f TestGitlabClientFactory) FromOauth2Token(token models.GitLabOauth2Token, enableClientCache bool) (core.GitlabClientFacade, error)

Jump to

Keyboard shortcuts

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