Documentation ¶
Index ¶
- func SetupHTTPTestAuthentication(req *http.Request, organization dbmodels.Organization, ...)
- type Context
- func (ctx Context) About(ginctx *gin.Context)
- func (ctx Context) CreateApplication(ginctx *gin.Context)
- func (ctx Context) CreateApplicationApprovalRulesetBinding(ginctx *gin.Context)
- func (ctx Context) CreateApprovalRuleset(ginctx *gin.Context)
- func (ctx *Context) CreateRelease(ginctx *gin.Context)
- func (ctx Context) DeleteApplicationApprovalRulesetBindingProposal(ginctx *gin.Context)
- func (ctx Context) DeleteApplicationProposal(ginctx *gin.Context)
- func (ctx Context) DeleteApprovalRulesetProposal(ginctx *gin.Context)
- func (ctx Context) GetApplication(ginctx *gin.Context)
- func (ctx Context) GetApplicationApprovalRulesetBinding(ginctx *gin.Context)
- func (ctx Context) GetApplicationApprovalRulesetBindingProposal(ginctx *gin.Context)
- func (ctx Context) GetApplicationApprovalRulesetBindingVersion(ginctx *gin.Context)
- func (ctx Context) GetApplicationProposal(ginctx *gin.Context)
- func (ctx Context) GetApplicationVersion(ginctx *gin.Context)
- func (ctx Context) GetApprovalRuleset(ginctx *gin.Context)
- func (ctx Context) GetApprovalRulesetProposal(ginctx *gin.Context)
- func (ctx Context) GetApprovalRulesetVersion(ginctx *gin.Context)
- func (ctx Context) GetCurrentOrganization(ginctx *gin.Context)
- func (ctx Context) GetOrganization(ginctx *gin.Context)
- func (ctx Context) GetRelease(ginctx *gin.Context)
- func (ctx Context) GetReleaseEvents(ginctx *gin.Context)
- func (ctx Context) InstallAuthenticatedRoutes(rg *gin.RouterGroup)
- func (ctx Context) InstallUnauthenticatedRoutes(rg *gin.RouterGroup)
- func (ctx Context) ListApplicationApprovalRulesetBindingProposals(ginctx *gin.Context)
- func (ctx Context) ListApplicationApprovalRulesetBindingVersions(ginctx *gin.Context)
- func (ctx Context) ListApplicationApprovalRulesetBindings(ginctx *gin.Context)
- func (ctx Context) ListApplicationProposals(ginctx *gin.Context)
- func (ctx Context) ListApplicationVersions(ginctx *gin.Context)
- func (ctx Context) ListApplications(ginctx *gin.Context)
- func (ctx Context) ListApprovalRulesetProposals(ginctx *gin.Context)
- func (ctx Context) ListApprovalRulesetVersions(ginctx *gin.Context)
- func (ctx Context) ListApprovalRulesets(ginctx *gin.Context)
- func (ctx Context) ListReleases(ginctx *gin.Context)
- func (ctx Context) UpdateApplication(ginctx *gin.Context)
- func (ctx Context) UpdateApplicationApprovalRulesetBinding(ginctx *gin.Context)
- func (ctx Context) UpdateApplicationApprovalRulesetBindingProposal(ginctx *gin.Context)
- func (ctx Context) UpdateApplicationApprovalRulesetBindingProposalState(ginctx *gin.Context)
- func (ctx Context) UpdateApplicationProposal(ginctx *gin.Context)
- func (ctx Context) UpdateApplicationProposalState(ginctx *gin.Context)
- func (ctx Context) UpdateApprovalRuleset(ginctx *gin.Context)
- func (ctx Context) UpdateApprovalRulesetProposal(ginctx *gin.Context)
- func (ctx Context) UpdateApprovalRulesetProposalState(ginctx *gin.Context)
- func (ctx Context) UpdateCurrentOrganization(ginctx *gin.Context)
- func (ctx Context) UpdateOrganization(ginctx *gin.Context)
- func (ctx Context) UpdateRelease(ginctx *gin.Context)
- type HTTPTestContext
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SetupHTTPTestAuthentication ¶
func SetupHTTPTestAuthentication(req *http.Request, organization dbmodels.Organization, orgMember dbmodels.IOrganizationMember)
SetupHTTPTestAuthentication sets up headers in the given request, so that the request is authenticated as the given organization member.
Types ¶
type Context ¶
func (Context) CreateApplication ¶
func (Context) CreateApplicationApprovalRulesetBinding ¶
func (Context) CreateApprovalRuleset ¶
func (*Context) CreateRelease ¶
func (Context) DeleteApplicationApprovalRulesetBindingProposal ¶
func (Context) DeleteApplicationProposal ¶
func (Context) DeleteApprovalRulesetProposal ¶
func (Context) GetApplication ¶
func (Context) GetApplicationApprovalRulesetBinding ¶
func (Context) GetApplicationApprovalRulesetBindingProposal ¶
func (Context) GetApplicationApprovalRulesetBindingVersion ¶
func (Context) GetApplicationProposal ¶
func (Context) GetApplicationVersion ¶
func (Context) GetApprovalRuleset ¶
func (Context) GetApprovalRulesetProposal ¶
func (Context) GetApprovalRulesetVersion ¶
func (Context) GetCurrentOrganization ¶
func (Context) GetOrganization ¶
func (Context) GetRelease ¶
func (Context) GetReleaseEvents ¶
func (Context) InstallAuthenticatedRoutes ¶
func (ctx Context) InstallAuthenticatedRoutes(rg *gin.RouterGroup)
func (Context) InstallUnauthenticatedRoutes ¶
func (ctx Context) InstallUnauthenticatedRoutes(rg *gin.RouterGroup)
func (Context) ListApplicationApprovalRulesetBindingProposals ¶
func (Context) ListApplicationApprovalRulesetBindingVersions ¶
func (Context) ListApplicationApprovalRulesetBindings ¶
func (Context) ListApplicationProposals ¶
func (Context) ListApplicationVersions ¶
func (Context) ListApplications ¶
func (Context) ListApprovalRulesetProposals ¶
func (Context) ListApprovalRulesetVersions ¶
func (Context) ListApprovalRulesets ¶
func (Context) ListReleases ¶
func (Context) UpdateApplication ¶
func (Context) UpdateApplicationApprovalRulesetBinding ¶
func (Context) UpdateApplicationApprovalRulesetBindingProposal ¶
func (Context) UpdateApplicationApprovalRulesetBindingProposalState ¶
func (Context) UpdateApplicationProposal ¶
func (Context) UpdateApplicationProposalState ¶
func (Context) UpdateApprovalRuleset ¶
func (Context) UpdateApprovalRulesetProposal ¶
func (Context) UpdateApprovalRulesetProposalState ¶
func (Context) UpdateCurrentOrganization ¶
func (Context) UpdateOrganization ¶
func (Context) UpdateRelease ¶
type HTTPTestContext ¶
type HTTPTestContext struct { Db *gorm.DB Engine *gin.Engine ControllerCtx Context Recorder *httptest.ResponseRecorder WaitGroup *sync.WaitGroup Org dbmodels.Organization ServiceAccount dbmodels.ServiceAccount }
func SetupHTTPTestContext ¶
func SetupHTTPTestContext(initializer func(ctx *HTTPTestContext, tx *gorm.DB) error) (HTTPTestContext, error)
func (HTTPTestContext) BodyJSON ¶
func (ctx HTTPTestContext) BodyJSON() (gin.H, error)
BodyJSON returns the response body as a JSON object.
func (HTTPTestContext) NewRequestWithAuth ¶
func (ctx HTTPTestContext) NewRequestWithAuth(method string, url string, body interface{}) (*http.Request, error)
NewRequestWithAuth creates a new Request which is already authenticated as `ctx.serviceAccount`.
`body` is either nil, or an object which will be marshalled into JSON as the request body.
func (HTTPTestContext) ServeHTTP ¶
func (ctx HTTPTestContext) ServeHTTP(req *http.Request)
Click to show internal directories.
Click to hide internal directories.