client.go 322 B

123456789101112131415
  1. package request
  2. import (
  3. "testing"
  4. "github.com/docker/docker/client"
  5. "github.com/stretchr/testify/require"
  6. )
  7. // NewAPIClient returns a docker API client configured from environment variables
  8. func NewAPIClient(t *testing.T) client.APIClient {
  9. clt, err := client.NewEnvClient()
  10. require.NoError(t, err)
  11. return clt
  12. }