miller/c/reg_test
Richard Patel 39cd68dd29
c/reg_test: make subprocess test libc-agnostic
A test in c/reg_test/run currently relies on glibc-specific
print buffering behavior in a test case that checks environment
vars with subprocesses.

The case in question made mlr spawn a script that prints a few lines
but also had mlr print lines itself at the same time. The order of
lines from mlr vs subprocess are undefined, producing a slightly
different outcome on Alpine Linux than on Glibc-based distributions.

This commit adds the "put -q" flag to the test case effectively
causing only the subprocess output to be printed (which is the one
the particular test case was interested in).

Relates to https://github.com/johnkerl/miller/issues/293
2020-08-24 22:14:38 +02:00
..
expected c/reg_test: make subprocess test libc-agnostic 2020-08-24 22:14:38 +02:00
input autoreconf -fiv 2020-01-26 10:31:43 -05:00
dev func-prohibits 2016-09-12 05:15:00 -07:00
Makefile.am fix travis build 2017-03-27 08:46:33 -04:00
Makefile.in autoreconf -fiv 2020-01-26 10:31:43 -05:00
README.md test-reorg iterate 2015-09-25 16:51:12 -04:00
run c/reg_test: make subprocess test libc-agnostic 2020-08-24 22:14:38 +02:00

There are two classes of testing for Miller:

  • C source-file names starting with test_ use MinUnit to unit-test various subsystems of interest. These are separate executables built and run by the build framework.

  • test/run runs the main mlr executable with canned inputs, comparing actual to canned outputs, to regression-test Miller's end-to-end operation.