tests

package
v0.33.0 Latest Latest
Warning

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

Go to latest
Published: Jul 8, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

README

tests

Cross-package integration tests that exercise schema against the mapof and sliceof carrier types together. Part of rosetta.

What matters here

  • This directory exists to break an import cycle, not because the tests are special. schema defines the Getter/Setter interfaces, and mapof/sliceof implement them — but schema cannot import mapof/sliceof in its own _test files without a cycle. Putting the round-trip tests in a separate tests package lets them import all three and verify that the implementations actually satisfy schema's path get/set contract.
  • testInline asserts a lossless round-trip: Set then Get returns the same value. It's the shared helper for "this value survives a schema write/read unchanged." Because schema.Set validates and may coerce, a test that fails here often means the value was rewritten by the schema, not that get/set is broken — check the element's validation rules first.

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

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