Re: Add regression tests for ROLE (USER) - Mailing list pgsql-hackers

From Andres Freund
Subject Re: Add regression tests for ROLE (USER)
Date
Msg-id 20130707155209.GA2062@alap2.anarazel.de
Whole thread Raw
In response to Re: Add regression tests for ROLE (USER)  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On 2013-07-07 11:11:49 -0400, Tom Lane wrote:
> Fabien COELHO <coelho@cri.ensmp.fr> writes:
> >> Generally, I think that the tests which return a syntax error are of 
> >> limited value and should probably be dropped.
> 
> > I think that it is not that simple: it is a good value to check that the 
> > syntax error message conveys a useful information for the user, and that 
> > changes to the parser rules do not alter good quality error messages.
> 
> It's good to check those things when a feature is implemented.  However,
> once it's done, the odds of the bison parser breaking are very low.
> Thus, the benefit of testing that over again thousands of times a day
> is pretty tiny.

There has been quite some talk about simplifying the grammar/scanner
though, if somebody starts to work on that *good* tests on syntax errors
might actually be rather worthwhile. Imo there's the danger of reducing
the specifity of error messages when doing so.
Granted, that probably mostly holds true for things actually dealing
with expressions...

Greetings,

Andres Freund

-- Andres Freund                       http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training &
Services



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Add regression tests for ROLE (USER)
Next
From: Tom Lane
Date:
Subject: Re: planner not choosing fastest estimated plan