2017-07-15 19:03:17 -04:00
|
|
|
package system
|
|
|
|
|
|
|
|
import (
|
2017-12-05 09:41:03 -05:00
|
|
|
"github.com/docker/docker/api/types"
|
2017-07-15 19:03:17 -04:00
|
|
|
"github.com/docker/docker/client"
|
2017-12-05 09:41:03 -05:00
|
|
|
"golang.org/x/net/context"
|
2017-07-15 19:03:17 -04:00
|
|
|
)
|
|
|
|
|
|
|
|
type fakeClient struct {
|
|
|
|
client.Client
|
|
|
|
|
2017-12-05 09:41:03 -05:00
|
|
|
version string
|
|
|
|
serverVersion func(ctx context.Context) (types.Version, error)
|
|
|
|
}
|
|
|
|
|
|
|
|
func (cli *fakeClient) ServerVersion(ctx context.Context) (types.Version, error) {
|
|
|
|
return cli.serverVersion(ctx)
|
2017-07-15 19:03:17 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
func (cli *fakeClient) ClientVersion() string {
|
|
|
|
return cli.version
|
|
|
|
}
|