package querytest

import "github.com/influxdata/flux/querytest"

Package querytest contains utilities for testing the query end-to-end.

Index

Functions

func NewQueryTestHelper

func NewQueryTestHelper(t *testing.T, tc NewQueryTestCase)

func RunAndCheckResult

func RunAndCheckResult(t testing.TB, querier *Querier, c flux.Compiler, d flux.Dialect, want string)

Types

type NewQueryTestCase

type NewQueryTestCase struct {
	Name    string
	Raw     string
	Want    *operation.Spec
	WantErr bool
}

type Querier

type Querier struct{}

func NewQuerier

func NewQuerier() *Querier

func (*Querier) Query

func (q *Querier) Query(ctx context.Context, w io.Writer, c flux.Compiler, d flux.Dialect) (int64, error)

Source Files

compile.go doc.go execute.go

Version
v0.196.1 (latest)
Published
Feb 19, 2025
Platform
linux/amd64
Imports
20 packages
Last checked
1 day ago

Tools for package owners.