psql - improve test coverage from 41% to 88%
Fabien COELHO <coelho@cri.ensmp.fr>
From: Fabien COELHO <coelho@cri.ensmp.fr>
To: PostgreSQL Developers <pgsql-hackers@lists.postgresql.org>
Date: 2019-08-28T14:31:00Z
Lists: pgsql-hackers
Attachments
- psql-tap-1.patch (text/x-diff) patch
Hello devs, The attached patch improves psql code coverage by adding a specific TAP test. The 1709 tests take 4 seconds CPU (6.3 elapsed time) on my laptop. The infrastructure is updated to require perl module "Expect", allowing to test interactive features such as tab completion and prompt changes. Coverage in "src/bin/psql" jumps from 40.0% of lines and 41.9% of functions to 78.4% of lines and 98.1% of functions with "check-world". -- Fabien.
Commits
-
Improve coverage of psql for backslash commands with \if and \elif
- aafe2762b152 13.0 landed
-
Fix comment in psql's describe.c
- 8a0deae8d9b6 13.0 landed