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: Dagfinn Ilmari Mannsåker <ilmari(at)ilmari(dot)org>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: bailing out in tap tests nearly always a bad idea
Date: 2022-02-14 17:58:41
Message-ID: 2910254.1644861521@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:
> Even just getting rid of the "Tests were run but no plan was declared and
> done_testing() was not seen." noise would be helpful. So I think using a fatal
> error routine that forced a failure to be recognized via ok(0, 'fatal error')
> and then does done_testing() would be better...

Maybe we could do something in an END block provided by Utils.pm?
I still think that insisting that people avoid die() is going to
be annoying.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Maciek Sakrejda 2022-02-14 18:12:22 Re: warn if GUC set to an invalid shared library
Previous Message Tom Lane 2022-02-14 17:54:47 Re: Mark all GUC variable as PGDLLIMPORT