Re: [HACKERS] Writing new unit tests with PostgresNode

2016-02-25 Thread Alvaro Herrera
Thanks, pushed. -- Álvaro Herrerahttp://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription:

Re: [HACKERS] Writing new unit tests with PostgresNode

2016-02-24 Thread Michael Paquier
On Tue, Feb 23, 2016 at 10:39 PM, Craig Ringer wrote: > Just finished doing that. Thanks for taking a look at the first patch so > quickly. I hope this one's better. > > FWIW I think you were right that using pod for the actual test wasn't the > best choice, I should've

Re: [HACKERS] Writing new unit tests with PostgresNode

2016-02-23 Thread Craig Ringer
On 23 February 2016 at 21:39, Craig Ringer wrote: > > Just finished doing that. Thanks for taking a look at the first patch so > quickly. I hope this one's better. > CF entry created. https://commitfest.postgresql.org/9/536/ -- Craig Ringer

Re: [HACKERS] Writing new unit tests with PostgresNode

2016-02-23 Thread Craig Ringer
On 23 February 2016 at 09:52, Michael Paquier wrote: > On Tue, Feb 23, 2016 at 12:29 AM, Alvaro Herrera > wrote: > > Craig Ringer wrote: > > > >> > +=pod > >> > + > >> > +=head2 Set up a node > >> > pod format... Do we really want that?

Re: [HACKERS] Writing new unit tests with PostgresNode

2016-02-22 Thread Michael Paquier
On Tue, Feb 23, 2016 at 12:29 AM, Alvaro Herrera wrote: > Craig Ringer wrote: > >> > +=pod >> > + >> > +=head2 Set up a node >> > pod format... Do we really want that? Considering that those modules >> > are only aimed at being dedicated for in-core testing, I would say

Re: [HACKERS] Writing new unit tests with PostgresNode

2016-02-22 Thread Alvaro Herrera
Craig Ringer wrote: > > +=pod > > + > > +=head2 Set up a node > > pod format... Do we really want that? Considering that those modules > > are only aimed at being dedicated for in-core testing, I would say no. > > If it's plain comments you have to scan through massive piles of verbose > Perl to

Re: [HACKERS] Writing new unit tests with PostgresNode

2016-02-22 Thread Craig Ringer
On 22 February 2016 at 20:21, Michael Paquier wrote: > On Mon, Feb 22, 2016 at 7:55 PM, Craig Ringer > wrote: > > Er, the patch is attached this time. > > top_builddir = ../.. > include $(top_builddir)/src/Makefile.global > > -SUBDIRS =

Re: [HACKERS] Writing new unit tests with PostgresNode

2016-02-22 Thread Michael Paquier
On Mon, Feb 22, 2016 at 7:55 PM, Craig Ringer wrote: > Er, the patch is attached this time. top_builddir = ../.. include $(top_builddir)/src/Makefile.global -SUBDIRS = regress isolation modules +SUBDIRS = regress isolation modules example_suite I have no problem with a

Re: [HACKERS] Writing new unit tests with PostgresNode

2016-02-22 Thread Craig Ringer
Er, the patch is attached this time. On 22 February 2016 at 18:54, Craig Ringer wrote: > On 22 February 2016 at 15:41, Michael Paquier > wrote: > > >> >> >> > Sound about right? I can tidy that up a bit and turn it into a README >> >> > and >>

Re: [HACKERS] Writing new unit tests with PostgresNode

2016-02-22 Thread Craig Ringer
On 22 February 2016 at 15:41, Michael Paquier wrote: > > >> > Sound about right? I can tidy that up a bit and turn it into a README > >> > and > >> > add a reference to that to the public tap docs to tell users where to > go > >> > if > >> > they want to write more

Re: [HACKERS] Writing new unit tests with PostgresNode

2016-02-21 Thread Abhijit Menon-Sen
At 2016-02-22 07:45:37 +, e...@xs4all.nl wrote: > > I think what's needed is: > > use 5.008_008; That is meant to fail if the code is run on a version of Perl older than 5.8.8, not fail if the code uses language features not present in 5.8.8. It is little help for those trying to maintain

Re: [HACKERS] Writing new unit tests with PostgresNode

2016-02-21 Thread Erik Rijkers
- All the core routines used should be compatible down to perl 5.8.8. Ugh. So not just Perl, ancient perl. I don't suppose Perl offers any kind of "compatible(5.8.8)" statement or anything? Do I have to compile a ten-year-old Perl and its dependencies to work on PostgreSQL tests?

Re: [HACKERS] Writing new unit tests with PostgresNode

2016-02-21 Thread Michael Paquier
On Mon, Feb 22, 2016 at 4:24 PM, Craig Ringer wrote: > On 22 February 2016 at 14:30, Michael Paquier > wrote: >> - All the core routines used should be compatible down to perl 5.8.8. > > Ugh. So not just Perl, ancient perl. > > I don't suppose

Re: [HACKERS] Writing new unit tests with PostgresNode

2016-02-21 Thread Craig Ringer
On 22 February 2016 at 14:30, Michael Paquier wrote: > +1. I will be happy to contribute into that. > Thanks. Hopefully what I wrote will be useful as a starting point. As I read through the modules I'll write some draft Perldoc too. > > The docs at

Re: [HACKERS] Writing new unit tests with PostgresNode

2016-02-21 Thread Michael Paquier
On Mon, Feb 22, 2016 at 2:19 PM, Craig Ringer wrote: > I've been taking a look at the Perl test infrastructure ( src/test/perl ) > for writing multi-node tests, starting with PostgresNode.pm and I have a few > comments based on my first approach to the code "cold". > > I

[HACKERS] Writing new unit tests with PostgresNode

2016-02-21 Thread Craig Ringer
Hi all I've been taking a look at the Perl test infrastructure ( src/test/perl ) for writing multi-node tests, starting with PostgresNode.pm and I have a few comments based on my first approach to the code "cold". I think a README in src/test/perl/ would be very helpful. It's currently not at