[check_postgres] issues with 'env -i make test'

Dan Stoner danstoner at gmail.com
Wed Nov 3 22:40:06 UTC 2021


Just getting started looking at the source code... trying to run the
tests as described in the README...


tldr; 'env -i make test' tells "make" to start without any environment
variables set... so the suggestions in the README to set additional
environment variables have no effect!

I think initdb and other pg binaries cannot be found:

$ env -i make test
PERL_DL_NONLAZY=1 "/usr/bin/perl" "-MExtUtils::Command::MM"
"-MTest::Harness" "-e" "undef *Test::Harness::Switches;
test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
t/00_basic.t ............... ok
t/00_release.t ............. skipped: Test skipped unless environment
variable RELEASE_TESTING is set
t/00_signature.t ........... skipped: Test skipped unless environment
variable RELEASE_TESTING is set
t/00_test_tester.t ......... skipped: Test skipped unless environment
variable RELEASE_TESTING is set
t/01_validate_range.t ...... ok
t/02_autovac_freeze.t ...... # Could not open
"test_database_check_postgres/data space/postgresql.conf": No such
file or directory
Bailout called.  Further testing stopped:  Cannot continue without a
test database
FAILED--Further testing stopped: Cannot continue without a test database
make: *** [test_dynamic] Error 255


If I remove the 'env -i' part and just run 'make test', things work just fine.

Sidenote:

$ env -i env

confirms that "env" has no environment present if started by "env -i".

This is on MacOS 11.6 Big Sur.

Regards,

- Dan Stoner


More information about the Check_postgres mailing list