test

package
v0.3.5 Latest Latest
Warning

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

Go to latest
Published: Mar 30, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func TestInferredTypeDir added in v0.3.4

func TestInferredTypeDir(t *testing.T, dirPath string, cycles int)

TestInferredTypeDir runs every .json file in dirPath as an inferred type test suite. Each file contains named test cases with a "generator_schema" (no explicit type — used for generation) and a "test_schema" (explicit type — used for validation). This proves that go-chaff's type inference produces values matching the explicitly-typed schema.

func TestInferredTypeFile added in v0.3.4

func TestInferredTypeFile(t *testing.T, path string, cycles int)

TestInferredTypeFile runs a single inferred type test file.

func TestJsonSchema

func TestJsonSchema(test *testing.T, schemaPath string, cycles int, options *chaff.ParserOptions, getGeneratorOptions func() *chaff.GeneratorOptions)

func TestJsonSchemaDir

func TestJsonSchemaDir(test *testing.T, dirPath string, cycles int)

func TestJsonSchemaDirWithConfig added in v0.2.0

func TestJsonSchemaDirWithConfig(test *testing.T, dirPath string, cycles int, options *chaff.ParserOptions, getGeneratorOptions func() *chaff.GeneratorOptions)

Types

This section is empty.

Jump to

Keyboard shortcuts

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