Documentation
¶
Overview ¶
Package mock contains mock implementations of the query package interfaces for testing.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AsyncQueryService ¶
type AsyncQueryService struct {
QueryF func(ctx context.Context, req *query.Request) (query.Query, error)
}
AsyncQueryService mocks the idep QueryService for testing.
type Compiler ¶
type Compiler struct {
CompileFn func(ctx context.Context) (*query.Spec, error)
Type query.CompilerType
}
func (Compiler) CompilerType ¶
func (c Compiler) CompilerType() query.CompilerType
type Executor ¶
type Executor struct {
ExecuteFn func(ctx context.Context, orgID platform.ID, p *plan.PlanSpec, a *execute.Allocator) (map[string]query.Result, error)
}
Executor is a mock implementation of an execute.Executor.
func NewExecutor ¶
func NewExecutor() *Executor
NewExecutor returns a mock Executor where its methods will return zero values.
type ProxyQueryService ¶
type ProxyQueryService struct {
QueryF func(ctx context.Context, w io.Writer, req *query.ProxyRequest) (int64, error)
}
ProxyQueryService mocks the idep QueryService for testing.
type QueryService ¶
type QueryService struct {
QueryF func(ctx context.Context, req *query.Request) (query.ResultIterator, error)
}
QueryService mocks the idep QueryService for testing.
func (*QueryService) Query ¶
func (s *QueryService) Query(ctx context.Context, req *query.Request) (query.ResultIterator, error)
Query writes the results of the query request.
Click to show internal directories.
Click to hide internal directories.