structpath

package
v0.0.0-...-5c99f88 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2019 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Structpath

type Structpath struct {
	// contains filtered or unexported fields
}

func AssertThatProto

func AssertThatProto(t *testing.T, proto proto.Message) *Structpath

Creates a new Structpath by marshaling the proto to JSON and then evaluating over that structure. This is the most generally useful form as serialization to JSON also automatically converts proto.Any and proto.Struct to the serialized JSON forms which can then be evaluated over. The downside is the loss of type fidelity for numeric types as JSON can only represent floats.

func (*Structpath) Accept

func (p *Structpath) Accept(path string, args ...interface{}) bool

func (*Structpath) Equals

func (p *Structpath) Equals(expected interface{}, path string, args ...interface{}) *Structpath

func (*Structpath) Exists

func (p *Structpath) Exists(path string, args ...interface{}) *Structpath

func (*Structpath) ForTest

func (p *Structpath) ForTest(t *testing.T) *Structpath

func (*Structpath) NotExists

func (p *Structpath) NotExists(path string, args ...interface{}) *Structpath

func (*Structpath) Select

func (p *Structpath) Select(path string, args ...interface{}) *Structpath

Jump to

Keyboard shortcuts

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