Re: Improved TAP tests by replacing sub-optimal uses of ok() with better Test::More functions
Michael Paquier <michael@paquier.xyz>
From: Michael Paquier <michael@paquier.xyz>
To: Sadhuprasad Patro <b.sadhu@gmail.com>
Cc: Andrew Dunstan <andrew@dunslane.net>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2025-10-31T00:48:48Z
Lists: pgsql-hackers
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Improve TAP tests by replacing ok() with better Test::More functions
- fabb33b351c2 19 (unreleased) landed
-
Fix matching check in recovery test 042_low_level_backup
- 61b5fa029a43 17.7 landed
- 3a7225ed37fc 18.1 landed
- d1b80a31ed6d 19 (unreleased) landed
-
pg_createsubscriber: Fix matching check in TAP test
- 39e22b3adaa7 18.1 landed
- d372888ade9e 19 (unreleased) landed
On Thu, Oct 30, 2025 at 05:00:27PM +0530, Sadhuprasad Patro wrote: > On Fri, Oct 17, 2025 at 11:11 AM Michael Paquier <michael@paquier.xyz> > wrote: >> -ok($node->log_contains(qr/no SSL error reported/) == 0, >> +is($node->log_contains(qr/no SSL error reported/), 0 >> >> The CI was failing with the change in the SSL tests, as of: >> [05:03:12.647] # at >> /tmp/cirrus-ci-build/src/test/ssl/t/001_ssltests.pl line 127. >> [05:03:12.647] # got: '' >> [05:03:12.647] # expected: '0' Sadhuprasad, there was still a bit more we could do. Related to this issue with the SSL test, what do you think about the introduction of a log_contains_like() in Cluster.pm where we would directly call like() in the subroutine? This way, we would be able to report in the output the contents of the server logs we are trying to match (or not match) with a pattern, making debugging easier. What do you think? -- Michael