Declarative schema
Each field declares a name, safe type and only the options that type needs, keeping fixtures compact and reviewable.
Day 065 / Testing / Synthetic Data
A dependency-free Python CLI that generates repeatable, privacy-safe synthetic JSON records from a small declarative schema.
Each field declares a name, safe type and only the options that type needs, keeping fixtures compact and reviewable.
A local random generator initialized with the chosen seed makes failures reproducible across repeated runs.
Synthetic labels and reserved example.test addresses avoid implying that generated records belong to real people.
Repeatable seeded fixtures
Five bounded field types
JSON and NDJSON output
Reserved test email addresses
No production-data dependency
Argparse, JSON, random, regex, pathlib and unittest keep the CLI portable and dependency-free.
The parser limits fields, choices, string lengths and record counts while rejecting duplicate and unknown input.
Tests cover reproducibility, seed changes, field ordering, every supported type, privacy-safe email output and invalid schemas.