From: | Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org> |
---|---|
To: | Andrew Dunstan <andrew(at)dunslane(dot)net> |
Cc: | Andres Freund <andres(at)anarazel(dot)de>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Using LibPq in TAP tests via FFI |
Date: | 2024-06-17 13:45:26 |
Message-ID: | 202406171345.7k3rpapg67xr@alvherre.pgsql |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 2024-Jun-17, Andrew Dunstan wrote:
> On 2024-06-17 Mo 5:07 AM, Alvaro Herrera wrote:
> > You made this function join the tuples from multiple queries together,
> > but the output format doesn't show anything for queries that return
> > empty. I think this strategy doesn't cater for the case of comparing
> > results from multiple queries very well, because it might lead to sets
> > of queries that return empty result for different queries reported as
> > identical when they aren't. Maybe add a separator line between the
> > results from each query, when there's more than one? (Perhaps just
> > "join('--\n', @results)" in that last line does the trick?)
>
> psql doesn't do that, and this is designed to mimic psql's behaviour. We
> could change that of course. I suspect none of the uses expect empty
> resultsets, so it's probably somewhat moot.
True -- I guess my comment should really be directed to the original
coding of the test in test_index_replay. I think adding the separator
line makes it more trustworthy.
Probably you're right that the current code of in-core tests don't care
about this, but if we export this technique to the world, I'm sure
somebody somewhere is going to care.
--
Álvaro Herrera 48°01'N 7°57'E — https://www.EnterpriseDB.com/
"The Gord often wonders why people threaten never to come back after they've
been told never to return" (www.actsofgord.com)
From | Date | Subject | |
---|---|---|---|
Next Message | Pavel Stehule | 2024-06-17 13:56:54 | Re: ON ERROR in json_query and the like |
Previous Message | Jelte Fennema-Nio | 2024-06-17 13:39:47 | Re: RFC: adding pytest as a supported test framework |