Documentation
¶
Overview ¶
Package gitalytest provides shared setup and assertions for Gitaly integration tests.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RequireMetadata ¶
func RequireMetadata(t *testing.T, server *testserver.TestGitalyServer, expected MetadataExpectations)
RequireMetadata asserts the common and command-specific Gitaly request metadata.
Types ¶
type CommandOptions ¶
type CommandOptions struct {
GitlabURL string
CommandType commandargs.CommandType
Repository string
RemoteAddr string
GitlabUsername string
GitlabKeyID string
CorrelationID string
ClientName string
}
CommandOptions defines the command test setup inputs.
type CommandSetup ¶
type CommandSetup struct {
Context context.Context
Config *config.Config
Args *commandargs.Shell
ReadWriter *readwriter.ReadWriter
Output *bytes.Buffer
}
CommandSetup contains the initialized dependencies for a command test.
func NewCommandSetup ¶
func NewCommandSetup(options CommandOptions) CommandSetup
NewCommandSetup initializes command arguments, context, configuration, and I/O.
type MetadataExpectations ¶
MetadataExpectations defines expected Gitaly request metadata.
type Servers ¶
type Servers struct {
GitlabURL string
Gitaly *testserver.TestGitalyServer
}
Servers contains the test services started for a network subtest.
Click to show internal directories.
Click to hide internal directories.