Runs every input in test/fixtures/corpus.exs through the real
filter_var(..., FILTER_VALIDATE_EMAIL) of your local php binary and
writes a golden verdict file to test/fixtures/golden/php-<version>.tsv.
These golden files are committed and are the oracle the differential tests
assert against, so anyone can verify parity with mix test even without PHP
installed. Regenerate them (e.g. after adding corpus cases, or to record a
new PHP version) with:
mix php.goldenThe functions in this module are also used by the live test suite, so the test-time and CLI generation paths are identical.
Summary
Functions
Loads all corpus inputs (binaries), de-duplicated, order preserved.
Absolute path to the php executable, or raises with guidance.
Glob of all committed golden files.
Path to the golden file for a given PHP version string.
Parses golden TSV text (with or without # header/comment lines) into a list
of {input_binary, default_valid?, unicode_valid?} tuples.
Invokes the PHP oracle (scripts/gen_golden.php) over the given inputs and
returns its raw TSV output: lines of base64_input\tdefault\tunicode.
Returns the PHP version string of the given binary (e.g. "8.5.5").
Functions
Loads all corpus inputs (binaries), de-duplicated, order preserved.
Two sources are merged:
test/fixtures/corpus.exs— curated, human-readable cases plus the programmatic length/boundary constructions.test/fixtures/corpus_catalog.b64— the authoritative byte-exact quirks catalog (base64 per line; fields after a tab are documentation).
Absolute path to the php executable, or raises with guidance.
Glob of all committed golden files.
Path to the golden file for a given PHP version string.
Parses golden TSV text (with or without # header/comment lines) into a list
of {input_binary, default_valid?, unicode_valid?} tuples.
Invokes the PHP oracle (scripts/gen_golden.php) over the given inputs and
returns its raw TSV output: lines of base64_input\tdefault\tunicode.
Returns the PHP version string of the given binary (e.g. "8.5.5").