Re: [PATCH] Tests for reloptions

From: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
To: Nikolay Shaplov <dhyan(at)nataraj(dot)su>
Cc: Michael Paquier <michael(dot)paquier(at)gmail(dot)com>, PostgreSQL mailing lists <pgsql-hackers(at)postgresql(dot)org>, Andres Freund <andres(at)anarazel(dot)de>
Subject: Re: [PATCH] Tests for reloptions
Date: 2017-10-19 12:20:52
Message-ID: 20171019122052.f3cychhfktrfwqdk@alvherre.pgsql
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Nikolay Shaplov wrote:
> В письме от 3 октября 2017 11:48:43 пользователь Michael Paquier написал:

> I've been thinking a lot, and rereading the patch. When I reread it I've been
> thinking that I would like to add more tests to it now... ;-)
>
> If the only purpose of tests is to get better coverage, then I would agree
> with you. But I've been thinking that tests also should check that everything
> behaves as expected (or as written in documentation).
>
> I would say that options names is a of part of SQL dialect that postgres uses,
> kind of part of the syntax. It is good to be sure that they still supported.
> So I would add a test for every option heap supports.

Yeah, it would perhaps be good idea to ensure we don't break things that
are documented to work. If the tests don't take too long, I'm not
opposed to testing every single option. As you say, code coverage is
important but it's not the only goal.

I'm hesitant to hardcode things like the number of bits in bloom, as you
had in the original. If I understand correctly, that number could
change with compile options (different blocksize?), so I removed that
part. I also fixed a few spelling errors.

And pushed. Let's see what the buildfarm says about this.

--
Álvaro Herrera https://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 Alvaro Herrera 2017-10-19 12:27:53 Re: [PATCH] Tests for reloptions
Previous Message Sokolov Yura 2017-10-19 12:10:54 Re: Fix performance degradation of contended LWLock on NUMA