Documentation ¶
Index ¶
- Constants
- func AssertGrpcError(t *testing.T, err error, expectedCode codes.Code, containsText string)
- func GitlabTestRepoPath() string
- func GitlabTestStoragePath() string
- func MustReadFile(t *testing.T, filename string) []byte
- func MustRunCommand(t *testing.T, stdin io.Reader, name string, args ...string) []byte
Constants ¶
View Source
const TestRelativePath = "gitlab-test.git"
TestRelativePath is the path inside its storage of the gitlab-test repo
Variables ¶
This section is empty.
Functions ¶
func AssertGrpcError ¶ added in v0.5.0
AssertGrpcError asserts the passed err is of the same code as expectedCode. Optionally, it can assert the error contains the text of containsText if the latter is not an empty string.
func GitlabTestRepoPath ¶ added in v0.5.0
func GitlabTestRepoPath() string
GitlabTestRepoPath returns the path to gitlab-test repo. Tests should be calling this function instead of cloning the repo themselves. Tests that involve modifications to the repo should copy/clone the repo via the path returned from this function.
func GitlabTestStoragePath ¶ added in v0.8.0
func GitlabTestStoragePath() string
GitlabTestStoragePath returns the storage path to the gitlab-test repo.
func MustReadFile ¶
MustReadFile returns the content of a file or fails at once.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.