Re: Test-cases for deferred constraints in plpgsql_transaction.sql

From: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
To: Ashutosh Sharma <ashu(dot)coek88(at)gmail(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Test-cases for deferred constraints in plpgsql_transaction.sql
Date: 2018-07-02 10:00:52
Message-ID: a76b7e9f-e57a-58cd-11f0-15c966d496e9@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 02.07.18 11:46, Ashutosh Sharma wrote:
> Currently, I could see only one test-case for deferred constraints in
> plpgsql_transaction.sql file which tests if the constraint checking is
> happening during commit time or not with the help of COMMIT statement.
> Shouldn't we add some more test-cases to test ROLLBACK and SET
> CONSTRAINTS statements with deferrable constraints inside DO blocks.

The purpose of that test is to check what happens when the COMMIT
command fails. Using deferrable constraints is just a way to trigger an
error coming from the COMMIT command.

I won't say we don't need more tests, but I don't see a particular
testing gap in this area.

--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Gierth 2018-07-02 10:04:14 Re: Should contrib modules install .h files?
Previous Message Konstantin Knizhnik 2018-07-02 09:59:57 Re: Global shared meta cache