testutils

package
v0.0.0-...-f8e07d0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 26, 2024 License: AGPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Combinations

func Combinations(arr []string, length int) [][]string

Combinations generates all Combinations of a given length from a slice of strings.

func LabelsToSeriesMetadata

func LabelsToSeriesMetadata(lbls []labels.Labels) []types.SeriesMetadata

func RequireEqualResults

func RequireEqualResults(t testing.TB, expr string, expected, actual *promql.Result, skipAnnotationComparison bool)

Why do we do this rather than require.Equal(t, expected, actual)? It's possible that floating point values are slightly different due to imprecision, but require.Equal doesn't allow us to set an allowable difference.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL