Documentation
¶
Index ¶
- func Begin(t *testing.T) (*manager.Media, context.Context)
- func Client(t *testing.T) *httpclient.Client
- func End(t *testing.T)
- func Main(m *testing.M, setup func(*manager.Media) (func(), error), opts ...manager.Opt)
- func ServerURL(t *testing.T) string
- func TaskManager(t *testing.T) *taskmanager.Manager
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Client ¶ added in v1.9.2
func Client(t *testing.T) *httpclient.Client
Client returns the shared HTTP client, wired to a test server with the standard handlers registered.
func Main ¶
Main is the test main function for tests. It starts up a container and runs the tests, providing a manager instance, and an HTTP client wired to a test server with the standard handlers registered, to each test.
func ServerURL ¶ added in v1.9.3
ServerURL returns the base URL of the shared test server - useful for a test that needs to make a raw HTTP request (e.g. a multipart upload with a custom Accept header) rather than going through Client.
func TaskManager ¶ added in v1.9.3
func TaskManager(t *testing.T) *taskmanager.Manager
TaskManager returns the shared task manager - useful for a test to wait on or inspect a task started by the Media under test (e.g. Media.Encode), which doesn't wait for completion itself.
Types ¶
This section is empty.