jsontest

package
v0.0.0-...-42663ac Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2024 License: MIT Imports: 6 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Array

type Array[T any] []T

type Asserter

type Asserter struct {
	JSON string
}

func NewAsserter

func NewAsserter(v interface{}) (*Asserter, error)

func (*Asserter) AssertEqual

func (d *Asserter) AssertEqual(t TB, path string, value interface{})

func (*Asserter) AssertEqualSet

func (d *Asserter) AssertEqualSet(t TB, path string, expected map[string]interface{})

func (*Asserter) AssertNotSet

func (d *Asserter) AssertNotSet(t TB, path string)

func (*Asserter) Get

func (d *Asserter) Get(path string) (interface{}, bool)

func (*Asserter) Print

func (d *Asserter) Print(t TB)

func (*Asserter) PrintAt

func (d *Asserter) PrintAt(t TB, path string)

type IsOneofKey

type IsOneofKey string

type LenEqual

type LenEqual int

type NotSet

type NotSet struct{}

type TB

type TB interface {
	Fatalf(format string, args ...interface{})
	Errorf(format string, args ...interface{})
	Log(args ...interface{})
	Helper()
}

type TestAsserter

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

func NewTestAsserter

func NewTestAsserter(t TB, v interface{}) *TestAsserter

func (*TestAsserter) AssertEqual

func (ta *TestAsserter) AssertEqual(path string, value interface{})

func (*TestAsserter) AssertEqualSet

func (ta *TestAsserter) AssertEqualSet(path string, expected map[string]interface{})

func (*TestAsserter) AssertNotSet

func (ta *TestAsserter) AssertNotSet(path string)

func (*TestAsserter) Get

func (ta *TestAsserter) Get(path string) (interface{}, bool)

func (*TestAsserter) Print

func (ta *TestAsserter) Print()

func (*TestAsserter) PrintAt

func (ta *TestAsserter) PrintAt(path string)

Jump to

Keyboard shortcuts

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