testutil

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package testutil provides the shared test fixture: FixtureSQL (the DDL both products' compose stacks and e2e suites load) and FixtureCatalog, a hand-built Catalog mirroring what introspecting that DDL yields, so builder and compiler tests run without a database. The drift gate in drift_test.go keeps the two aligned.

Index

Constants

This section is empty.

Variables

View Source
var FixtureSQL string

FixtureSQL is the fixture schema DDL (embedded from fixture.sql).

Functions

func FixtureCatalog

func FixtureCatalog() *introspect.Catalog

FixtureCatalog models FixtureSQL after introspection: users (pk id, unique email, enum mood + mood[], jsonb, text[], composite address + address[]), posts (pk id, fk author_id -> users.id, RLS), comments (self-referential), places (PostGIS geometry + geography, GiST-indexed), events (type_code bound to the table-backed event_type enum), the metrics view, the jwt composite, and the functions. Slices follow introspection order (indexes and constraints by name); PostGIS's own relations/composites are absent.

Types

This section is empty.

Directories

Path Synopsis
cmd
fixture command
Command fixture prints testutil.FixtureSQL so product repos can generate their compose init script from the module:
Command fixture prints testutil.FixtureSQL so product repos can generate their compose init script from the module:

Jump to

Keyboard shortcuts

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