
* build: add goimports to fmt target to remove unused imports * feat: update codegen template to support returning raw response body * feat: add support for gunzip-ing response bodies * refactor: remove unused piece from codegen return values
24 lines
491 B
Go
24 lines
491 B
Go
package mock
|
|
|
|
import (
|
|
"context"
|
|
|
|
"github.com/influxdata/influx-cli/v2/internal/api"
|
|
)
|
|
|
|
var _ api.HealthApi = (*HealthApi)(nil)
|
|
|
|
type HealthApi struct {
|
|
GetHealthExecuteFn func(api.ApiGetHealthRequest) (api.HealthCheck, error)
|
|
}
|
|
|
|
func (p *HealthApi) GetHealth(context.Context) api.ApiGetHealthRequest {
|
|
return api.ApiGetHealthRequest{
|
|
ApiService: p,
|
|
}
|
|
}
|
|
|
|
func (p *HealthApi) GetHealthExecute(req api.ApiGetHealthRequest) (api.HealthCheck, error) {
|
|
return p.GetHealthExecuteFn(req)
|
|
}
|