Re: Writing new unit tests with PostgresNode
От | Michael Paquier |
---|---|
Тема | Re: Writing new unit tests with PostgresNode |
Дата | |
Msg-id | CAB7nPqS-zOLYz0prsC=LmjkWf_QR8P0SxWMVFg0+3ZUg-R3igg@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: Writing new unit tests with PostgresNode (Craig Ringer <craig@2ndquadrant.com>) |
Ответы |
Re: Writing new unit tests with PostgresNode
(Craig Ringer <craig@2ndquadrant.com>)
|
Список | pgsql-hackers |
On Mon, Feb 22, 2016 at 4:24 PM, Craig Ringer <craig@2ndquadrant.com> wrote: > On 22 February 2016 at 14:30, Michael Paquier <michael.paquier@gmail.com> > 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 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? > http://search.cpan.org/dist/Perl-MinimumVersion/lib/Perl/MinimumVersion.pm > looks useful; do you think it's reasonable for code that passes that check > to just be thrown at the buildfarm? No, I don't use those old versions :) Module::CoreList->first_release is one way to do that for a module: $ perl -MModule::CoreList -e ' print Module::CoreList->first_release('Test::More'), "\n";' 5.006002 Last time I was dealing with that I had as well a look at http://perldoc.perl.org/, which was quite helpful by browsing through each version. >> > 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 tests. >> >> Yes, please. > > Will do that now. This is definitely independent from the efforts of the other patches. >> > I don't know how many suites we'll want - whether it'll be desirable to >> > have >> > a few suites with lots of tests or to have lots of suites with just a >> > few >> > tests. I'm planning on starting by adding a suite named 'replication' >> > and >> > putting some tests for failover slots in there. Reasonable? >> >> It seems to me that the failover slot tests should be part of the >> recovery test suite I have proposed already. Those are located in >> src/test/recovery, introducing as well a set of routines in >> PostgresNode.pm that allows one to pass options to PostgresNode::init >> to enable archive or streaming on a given node. I would believe that >> any replication suite is going to need that, and I have done a bunch >> of legwork to make sure that this works on Windows as well. > > > Not committed yet, I see. That's https://commitfest.postgresql.org/9/438/ > right? Yeah... That's life. > I'd rather not duplicate your work there, so I should build on that. Is > there a public git tree for that? The latest set of patches is here: https://github.com/michaelpq/postgres/commits/recovery_regression Those are the ones I sent a couple of days back on -hackers. Hopefully those will get integrated into the core code. -- Michael
В списке pgsql-hackers по дате отправления: