runtestverdicts

package
v0.0.0-...-a70aae3 Latest Latest
Warning

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

Go to latest
Published: Nov 14, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Overview

Package runtestverdicts provides methods to query test verdicts within a test run (single invocation excluding included invocation).

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PageToken

type PageToken struct {
	AfterTestID      string
	AfterVariantHash string
}

PageToken represents a pagination position in the query.

func ParsePageToken

func ParsePageToken(token string) (PageToken, error)

ParsePageToken parses a page token string into a PageToken.

func (PageToken) Serialize

func (t PageToken) Serialize() string

Serialize serializes the page token.

type Query

type Query struct {
	InvocationID       invocations.ID
	PageSize           int // must be non-negative
	PageToken          PageToken
	ResultLimit        int // must be non-negative
	ResponseLimitBytes int // maximum response size in bytes (soft limit)
}

Query specifies the run test verdicts to fetch.

func (*Query) Run

func (q *Query) Run(ctx context.Context) (result QueryResult, err error)

Run queries the run's test verdicts. It behaves deterministically, returning the maximum number of test verdicts consistent with the requested PageSize and ResponseLimitBytes, in ascending (test, variantHash) order.

Must be run in a transactional spanner context supporting multiple reads.

type QueryResult

type QueryResult struct {
	// The test verdicts retrieved.
	//
	// Within each test verdict, results are ordered with unexpected results
	// first, then by result ID.
	RunTestVerdicts []*pb.RunTestVerdict
	// The continuation token. If this is empty, then there are no more
	// test verdicts to retrieve.
	NextPageToken PageToken
}

QueryResult is the result of a Query.

Jump to

Keyboard shortcuts

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