gitea: code.gitea.io/gitea/modules/test Index | Files

package test

import "code.gitea.io/gitea/modules/test"

Index

Package Files

context_tests.go utils.go

func LoadGitRepo Uses

func LoadGitRepo(t *testing.T, ctx *context.Context)

LoadGitRepo load a git repo into a test context. Requires that ctx.Repo has already been populated.

func LoadRepo Uses

func LoadRepo(t *testing.T, ctx *context.Context, repoID int64)

LoadRepo load a repo into a test context.

func LoadRepoCommit Uses

func LoadRepoCommit(t *testing.T, ctx *context.Context)

LoadRepoCommit loads a repo's commit into a test context.

func LoadUser Uses

func LoadUser(t *testing.T, ctx *context.Context, userID int64)

LoadUser load a user into a test context.

func MockContext Uses

func MockContext(t *testing.T, path string) *context.Context

MockContext mock context for unit tests

func RedirectURL Uses

func RedirectURL(resp http.ResponseWriter) string

RedirectURL returns the redirect URL of a http response.

Package test imports 10 packages (graph). Updated 2019-08-28. Refresh now. Tools for package owners.