Re: bailing out in tap tests nearly always a bad idea

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: bailing out in tap tests nearly always a bad idea
Date: 2022-02-13 23:32:59
Message-ID: 2744434.1644795179@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Andres Freund <andres(at)anarazel(dot)de> writes:
> Does anybody want to defend / explain the use of BAIL_OUT? If not, I think we
> should consider doing a global replace of the use of bailing.

+1

> Best with a
> central function signalling fatal error, rather than individual uses of die
> or such.

Huh, doesn't Test::More already provide a sane way to do this?
If not, why isn't die() good enough? (I don't think you can
realistically expect to prohibit die() anywhere in the TAP tests.)

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Dunstan 2022-02-13 23:34:00 Re: xml_is_well_formed (was Re: buildfarm warnings)
Previous Message Andrew Dunstan 2022-02-13 23:31:57 Re: buildfarm warnings