Documentation
¶
Overview ¶
Command regenerate derives every golden in parser/testdata from the pinned oracle (libpg_query 18.0.0 via pg_query_go v6.2.2, cgo). It is the only writer of that tree; expected outputs are NEVER edited by hand.
go run ./cmd/regenerate -libpg-query <checkout@18.0.0> -pg-query-go <checkout@v6.2.2>
Corpus tiers extracted:
- test/sql/postgres_regress/*.sql → parse, scan, normalize, fingerprint, deparse suites (the PostgreSQL regression suite; psql metacommands and COPY-FROM-stdin payloads filtered)
- test/sql/deparse/*.sql, deparse-depesz/*.sql → parse, scan, deparse
- inline test tables (test/*_tests.c) → their respective suites (inputs transcribed mechanically; expectations always from the oracle)
- pg_query_go testdata/fingerprint.json → fingerprint suite (includes the 1.1 MB stress insert)
Output must be byte-identical across runs — that reproducibility is milestone 2's acceptance gate and is enforced weekly in CI.
Click to show internal directories.
Click to hide internal directories.