nodetest

package
v0.32.2 Latest Latest
Warning

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

Go to latest
Published: Aug 17, 2025 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewNode

func NewNode[T any](data T) nodes.Node

func NewPortValue

func NewPortValue[T any](data T) nodes.Output[T]

Types

type AssertNodeDescription

type AssertNodeDescription struct {
	Description string
}

func (AssertNodeDescription) Assert

func (apv AssertNodeDescription) Assert(t *testing.T, node nodes.Node)

type AssertNodeInputPortDescription

type AssertNodeInputPortDescription struct {
	Port        string
	Description string
}

func NewAssertInputPortDescription

func NewAssertInputPortDescription(port, description string) AssertNodeInputPortDescription

func (AssertNodeInputPortDescription) Assert

func (apv AssertNodeInputPortDescription) Assert(t *testing.T, node nodes.Node)

type AssertNodeOutputPortDescription added in v0.32.0

type AssertNodeOutputPortDescription struct {
	Port        string
	Description string
}

func (AssertNodeOutputPortDescription) Assert added in v0.32.0

func (apv AssertNodeOutputPortDescription) Assert(t *testing.T, node nodes.Node)

type AssertOutputPortValue added in v0.32.0

type AssertOutputPortValue[T any] struct {
	Port            string
	Value           T
	ExecutionReport *nodes.ExecutionReport
}

func AssertOutput added in v0.31.0

func AssertOutput[T any](port string, value T) AssertOutputPortValue[T]

func (AssertOutputPortValue[T]) Assert added in v0.32.0

func (apv AssertOutputPortValue[T]) Assert(t *testing.T, node nodes.Node)

type Assertion

type Assertion interface {
	Assert(t *testing.T, node nodes.Node)
}

type Suite

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

func NewSuite

func NewSuite(cases ...TestCase) Suite

func (Suite) Run

func (s Suite) Run(t *testing.T)

type TestCase

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

func NewTestCase

func NewTestCase(name string, node nodes.Node, assertions ...Assertion) TestCase

func (TestCase) Run

func (tc TestCase) Run(t *testing.T)

Jump to

Keyboard shortcuts

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